diff options
author | Nick Desaulniers <ndesaulniers@google.com> | 2017-08-11 11:16:07 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-04-08 11:51:57 +0200 |
commit | a8f9bab69bb3d7796615cac7ecaffea2b7b6d3c8 (patch) | |
tree | 206d36bec880140aa0ffe837cea4a3befe238591 /kernel/irq/manage.c | |
parent | 1a4106d686784f207addbfbf5137413bc17ff28d (diff) |
netfilter: nf_nat_h323: fix logical-not-parentheses warning
commit eee6ebbac18a189ef33d25ea9b8bcae176515e49 upstream.
Clang produces the following warning:
net/ipv4/netfilter/nf_nat_h323.c:553:6: error:
logical not is only applied to the left hand side of this comparison
[-Werror,-Wlogical-not-parentheses]
if (!set_h225_addr(skb, protoff, data, dataoff, taddr,
^
add parentheses after the '!' to evaluate the comparison first
add parentheses around left hand side expression to silence this warning
There's not necessarily a bug here, but it's cleaner to return early,
ex:
if (x)
return
...
rather than:
if (x == 0)
...
else
return
Also added a return code check that seemed to be missing in one
instance.
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/irq/manage.c')
0 files changed, 0 insertions, 0 deletions