From: Maciej Zenczykowski Date: Tue, 5 Apr 2011 10:42:37 +0000 (+0200) Subject: move 'int line' definition from ip6?tables.c into xtables.c X-Git-Tag: v1.4.11~31 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=37911de507d0597980ad218a044a482501a21b01;p=thirdparty%2Fiptables.git move 'int line' definition from ip6?tables.c into xtables.c Signed-off-by: Maciej Zenczykowski Signed-off-by: Patrick McHardy --- diff --git a/ip6tables.c b/ip6tables.c index 15508d6e..ea9a7abf 100644 --- a/ip6tables.c +++ b/ip6tables.c @@ -127,12 +127,6 @@ static struct option original_opts[] = { {NULL}, }; -/* we need this for ip6tables-restore. ip6tables-restore.c sets line to the - * current line of the input file, in order to give a more precise error - * message. ip6tables itself doesn't need this, so it is initialized to the - * magic number of -1 */ -int line = -1; - void ip6tables_exit_error(enum xtables_exittype status, const char *msg, ...) __attribute__((noreturn, format(printf,2,3))); struct xtables_globals ip6tables_globals = { .option_offset = 0, diff --git a/iptables.c b/iptables.c index 0995d6f3..cf272278 100644 --- a/iptables.c +++ b/iptables.c @@ -126,12 +126,6 @@ static struct option original_opts[] = { {NULL}, }; -/* we need this for iptables-restore. iptables-restore.c sets line to the - * current line of the input file, in order to give a more precise error - * message. iptables itself doesn't need this, so it is initialized to the - * magic number of -1 */ -int line = -1; - void iptables_exit_error(enum xtables_exittype status, const char *msg, ...) __attribute__((noreturn, format(printf,2,3))); struct xtables_globals iptables_globals = { diff --git a/xtables.c b/xtables.c index 4c708b8e..339a25b7 100644 --- a/xtables.c +++ b/xtables.c @@ -57,6 +57,12 @@ #define PROC_SYS_MODPROBE "/proc/sys/kernel/modprobe" #endif +/* we need this for ip6?tables-restore. ip6?tables-restore.c sets line to the + * current line of the input file, in order to give a more precise error + * message. ip6?tables itself doesn't need this, so it is initialized to the + * magic number of -1 */ +int line = -1; + void basic_exit_err(enum xtables_exittype status, const char *msg, ...) __attribute__((noreturn, format(printf,2,3))); struct xtables_globals *xt_params = NULL;