Open mtasaka opened 5 months ago
Since C operator precedence says !=
is higher than &
, the code
if (pfd.revents & POLLOUT != POLLOUT)
is interpreted as
if (pfd.revents & (POLLOUT != POLLOUT) )
... which is always false because POLLOUT != POLLOUT
is always evaluated as 0
. I don't think this is intended.
Hi @dinhvh !
I've also added this to Debian patches [1], would be nice to have it merged before next release. Thanks go to @mtasaka for the patch :smile_cat:
best regards,
Fixes the following warnings: