[Date Prev][Date Next]
Patch: 'unsigned < 0' doesn't work (ITS#1705)
Full_Name: Hallvard B. Furuseth
Submission from: (NULL) (220.127.116.11)
This code tested whether an unsigned variable was negative.
In dntest.c, the bug happened if strlen(buf)==0.
In entropy.c, the code didn't catch if the return value from read() was
-1. -1 is converted to U<TYPE>_MAX when it meets `unsigned <type>'.