diff options
author | Jamal Hadi Salim <hadi@cyberus.ca> | 2009-02-11 13:05:43 +0100 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2009-02-11 13:05:43 +0100 |
commit | 8b7baebc93989106fd5d26b262d0ce191f8ef7c0 (patch) | |
tree | 7f320fe1b60ff07e537149541da0f46316631996 /iptables-xml.c | |
parent | 7878483dfaf91adcdb7e8e88c93ded82312af39a (diff) |
libxtables: simple aliasing macro for exit_error
Rename xtables_globals exit_error cb to exit_err and introduce
a very simple aliasing macro to point to it.
convert iptables, ip6tables and iptables_xml to use it.
Note iptables_xml does not have to define its own exit_error()
since it can use the basic one provided.
Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'iptables-xml.c')
-rw-r--r-- | iptables-xml.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/iptables-xml.c b/iptables-xml.c index 329c5983..4bb05578 100644 --- a/iptables-xml.c +++ b/iptables-xml.c @@ -31,18 +31,6 @@ const char *program_version; #ifndef IPTABLES_MULTI int line = 0; -void exit_error(enum xtables_exittype status, const char *msg, ...) -{ - va_list args; - - va_start(args, msg); - fprintf(stderr, "%s v%s: ", program_name, program_version); - vfprintf(stderr, msg, args); - va_end(args); - fprintf(stderr, "\n"); - /* On error paths, make sure that we don't leak memory */ - exit(status); -} #endif static void print_usage(const char *name, const char *version) @@ -634,7 +622,6 @@ struct xtables_globals iptables_xml_globals = { .option_offset = 0, .program_version = IPTABLES_VERSION, .program_name = "iptables-xml", - .exit_error = exit_error, }; #ifdef IPTABLES_MULTI |