diff options
Diffstat (limited to 'src/iptables.c')
-rwxr-xr-x | src/iptables.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/iptables.c b/src/iptables.c index 2ee9485a..90a296e2 100755 --- a/src/iptables.c +++ b/src/iptables.c @@ -2947,7 +2947,7 @@ static int parse_ip_and_mask(const char *str, struct in_addr *ip, if (!tokens) return -1; - if (!inet_pton(AF_INET, tokens[0], ip)) { + if (inet_pton(AF_INET, tokens[0], ip) != 1) { err = -1; goto out; } @@ -2988,7 +2988,7 @@ static int parse_ipv6_and_mask(const char *str, struct in6_addr *ip, if (!tokens) return -1; - if (!inet_pton(AF_INET6, tokens[0], ip)) { + if (inet_pton(AF_INET6, tokens[0], ip) != 1) { err = -1; goto out; } @@ -3399,7 +3399,7 @@ static int parse_rule_spec(struct connman_iptables *table, break; if (invert) - ctx->ip->invflags |= IP6T_INV_DSTIP; + ctx->ipv6->invflags |= IP6T_INV_DSTIP; } break; |