lcp / mokutil

The utility to manipulate machine owner keys
GNU General Public License v3.0
67 stars 37 forks source link

Fix compile failure on platforms where int != unsigned int #19

Closed vorlonofportland closed 5 years ago

vorlonofportland commented 5 years ago

The compiler may rightly warn about a comparison between an unsigned int and an int on architectures where int is signed by default. Since the existing code has been tested on architectures where int is unsigned, we just make our other int explicitly unsigned, ignoring certain existing corner cases for now wrt possible integer underflows.

Signed-off-by: Steve Langasek steve.langasek@canonical.com

vorlonofportland commented 5 years ago

I am reminded that int is always signed (I had a brainfart and was thinking of char), and therefore the rationale for this change is garbage.