diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2013-06-17 08:45:55 +0200 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2013-06-17 08:45:55 +0200 |
commit | 8c57f8bb2b04372e0f4fe70d2759a90efe23921f (patch) | |
tree | 855f1d303f0dd4d139ff963389f6bdf0e59ee74b | |
parent | c915e3e028f2b66b5b780433eae2d19c10575fac (diff) |
Remove useless test that is always evaluated as true.
gcc -DHAVE_CONFIG_H -I. -I.. -DAX25_SYSCONFDIR=\""/usr/local/etc/ax25"\" -DAX25_ LOCALSTATEDIR=\""/usr/local/var/ax25"\" -O2 -Wall -Wno-pointer-sign -MT list
ener.o -MD -MP -MF .deps/listener.Tpo -c -o listener.o listener.c
listener.c: In function ‘set_route’:
listener.c:232:6: warning: the address of ‘iproute2_table’ will always evaluate as ‘true’ [-Waddress]
listener.c: In function ‘del_kernel_ip_route’:
listener.c:278:6: warning: the address of ‘iproute2_table’ will always evaluate as ‘true’ [-Waddress]
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
-rw-r--r-- | ax25rtd/listener.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ax25rtd/listener.c b/ax25rtd/listener.c index ab84889..9dce370 100644 --- a/ax25rtd/listener.c +++ b/ax25rtd/listener.c @@ -229,7 +229,7 @@ int set_route(config * config, long ip) if (!config->ip_add_route) return 0; - if (iproute2_table && *iproute2_table) + if (*iproute2_table) return iproute2(ip, config->dev, RT_ADD); fds = socket(AF_INET, SOCK_DGRAM, 0); @@ -275,7 +275,7 @@ int del_kernel_ip_route(char *dev, long ip) if (config == NULL || !config->ip_add_route) return 0; - if (iproute2_table && *iproute2_table) + if (*iproute2_table) return iproute2(ip, dev, RT_DEL); fds = socket(AF_INET, SOCK_DGRAM, 0); |