!(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.
return h_size;
}
- if (!(hdr->nflog_version) == 0) {
+ if (hdr->nflog_version != 0) {
ND_PRINT((ndo, "version %u (unknown)", hdr->nflog_version));
return h_size;
}