Tag: 8e64159dfb480b30233d947d5a3cd793dfea738f

net: dccp: fix sign bug

Author: Kulikov Vasiliy <segooon@gmail.com> ‘gap’ is unsigned, so this code is wrong: gap = -new_head; … if (gap > 0) { … } Make ‘gap’ signed. The semantic patch that finds this problem (many false-positive results): (http://coccinelle.lip6.fr/) // @ r1 @ identifier f; @@ int f(…) { … } @@ identifier r1.f; type T; unsigned …

Continue reading