]> The Tcpdump Group git mirrors - tcpdump/commit
Clean up version test.
authorGuy Harris <[email protected]>
Fri, 25 Mar 2016 19:51:08 +0000 (12:51 -0700)
committerGuy Harris <[email protected]>
Fri, 25 Mar 2016 19:51:08 +0000 (12:51 -0700)
commit39e332e70d48995195d271cabd459894e4713d64
treef4012277d86be2d9e80b5e6e145dd93c813dbbda
parent3d11d28ba07fffcbfd460cdb1fe95eded061e2f3
Clean up version test.

!(nfhdr->nflog_version) is equivalent to (nfhdr->nflog_version == 0).

That will evaluate to 1 if nfhdr->nflog_version is 0 and to 0 otherwise.

So !(nfhdr->nflog_version) == 0 is equivalent to nfhdr->nflog_version != 0,
but 1) it's more obvious what it means and 2) compilers don't point out
that it may not mean what you intended.
print-nflog.c