diff options
author | Zhang zhengguang <zhengguang.zhang@intel.com> | 2014-07-17 10:37:39 +0800 |
---|---|---|
committer | Zhang zhengguang <zhengguang.zhang@intel.com> | 2014-07-17 10:37:39 +0800 |
commit | 1b9d0a62f59bb48c8deb2f0b98d9acdffdd9abe7 (patch) | |
tree | 6e991827d28537f7f40f20786c2354fd04a9fdad /tools/iptables-test.c | |
parent | fbe905ab58ecc31fe64c410c5f580cadc30e7f04 (diff) | |
download | connman-1b9d0a62f59bb48c8deb2f0b98d9acdffdd9abe7.tar.gz connman-1b9d0a62f59bb48c8deb2f0b98d9acdffdd9abe7.tar.bz2 connman-1b9d0a62f59bb48c8deb2f0b98d9acdffdd9abe7.zip |
Imported Upstream version 1.24upstream/1.24
Diffstat (limited to 'tools/iptables-test.c')
-rw-r--r-- | tools/iptables-test.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/iptables-test.c b/tools/iptables-test.c index 1d964b9a..2df53ccd 100644 --- a/tools/iptables-test.c +++ b/tools/iptables-test.c @@ -49,7 +49,7 @@ int main(int argc, char *argv[]) opterr = 0; while ((c = getopt_long(argc, argv, - "-A:I:D:P:N:X:F:Lt:", NULL, NULL)) != -1) { + "-A:I:D:P:N:X:F:Lt:", NULL, NULL)) != -1) { switch (c) { case 'A': chain = optarg; @@ -92,11 +92,11 @@ int main(int argc, char *argv[]) } out: - if (table == NULL) + if (!table) table = "filter"; for (i = optind - 1; i < argc; i++) { - if (rule != NULL) { + if (rule) { tmp = rule; rule = g_strdup_printf("%s %s", rule, argv[i]); g_free(tmp); @@ -129,7 +129,7 @@ out: err = __connman_iptables_flush_chain(table, chain); break; case IPTABLES_COMMAND_DUMP: - __connman_log_init(argv[0], "*", FALSE, FALSE, + __connman_log_init(argv[0], "*", false, false, "iptables-test", "1"); err = __connman_iptables_dump(table); break; |