[Swan-dev] [PATCH libreswan v2] netlink: Silence negative shift coverity false warning

D. Hugh Redelmeier hugh at mimosa.com
Sat Sep 16 03:17:43 UTC 2017


| From: Antony Antony <antony at phenome.org>

coverity-detected anomalies are sometimes subtle.  So I looked at this
code and found a couple of bugs.  I also did some tidying.  But no
testing!

Aviv, Antony: please have a look at commit
f7aaa80198851ef71da4be8dc54e816f7064e29a

Note: % 31 is almost never correct.  I think that in this code, + 31 is 
also wrong.

Could someone with real hardware test this code?

I cannot see that the old code would use NIC offload since the test for 
the feature seemed to be backwards.

Of course I could be backwards.

Knuth said: Beware of bugs in the above code; I have only proved it correct.

I haven't even proved these changes.



More information about the Swan-dev mailing list