diff options
author | Stef Walter <stefw@redhat.com> | 2016-01-10 09:33:03 +0100 |
---|---|---|
committer | Stef Walter <stefw@redhat.com> | 2016-01-10 09:33:03 +0100 |
commit | 2ba29d4fbd61cb3c99cb19f190a25855f4a980fe (patch) | |
tree | 883a4d3aa9fddef03a7c0dd40976815320130a17 /common | |
parent | 0fd80a21185e4c8fb3c77d7e0f241a2149fe8fc6 (diff) |
common: Fix use of && instead of &
Diffstat (limited to 'common')
-rw-r--r-- | common/sock-any.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/common/sock-any.c b/common/sock-any.c index 4613931..5155a30 100644 --- a/common/sock-any.c +++ b/common/sock-any.c @@ -371,14 +371,14 @@ sock_any_cmp (const struct sockaddr_any* a1, const struct sockaddr_any* a2, int case AF_INET: if (memcmp (&(a1->s.in.sin_addr), &(a2->s.in.sin_addr), sizeof(a2->s.in.sin_addr)) != 0) return -1; - if (!(opts && SANY_OPT_NOPORT) && a1->s.in.sin_port != a2->s.in.sin_port) + if (!(opts & SANY_OPT_NOPORT) && a1->s.in.sin_port != a2->s.in.sin_port) return -1; return 0; #ifdef HAVE_INET6 case AF_INET6: if(memcmp(&(a1->s.in6.sin6_addr), &(a2->s.in6.sin6_addr), sizeof(a2->s.in6.sin6_addr)) != 0) return -1; - if(!(opts && SANY_OPT_NOPORT) && a1->s.in6.sin6_port != a2->s.in6.sin6_port) + if(!(opts & SANY_OPT_NOPORT) && a1->s.in6.sin6_port != a2->s.in6.sin6_port) return -1; return 0; #endif |