]> git.proxmox.com Git - pve-firewall.git/commit - src/pvefw-logger.c
fix ambiguous if statements
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 13 Dec 2016 12:13:39 +0000 (13:13 +0100)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Tue, 13 Dec 2016 13:32:32 +0000 (14:32 +0100)
commit0dc6e6387e38d51f07b57fdb3ddcf45d24ee92d8
treedcd78981350b17d65f25b2fcb15fb2d984f7029b
parentdf67a3dc5f407d16f56fe9cf6b236195fe1546de
fix ambiguous if statements

the funciton nflog_bind_pf(...) returns an integer smaller 0 on a
failure, we negated that which results in 1 if no failure and 0 if
there was a failure.
This is ambiguous and as no parenthesis are set the GCC 6 warning
"logical-not-parentheses" gets triggered.

Use a simple
    nflog_bind_pf(...) < 0
check instead.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/pvefw-logger.c