[Bug 245200] emulators/emu64 : Fails to build on FreeBSD 12.1-RELEASE-p1 powerpc 32 bit: error: narrowing conversion of '-1' from 'int' to 'char' [-Wnarrowing]
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Thu Apr 2 19:05:54 UTC 2020
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=245200
Justin Hibbits <jhibbits at FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jhibbits at FreeBSD.org
--- Comment #7 from Justin Hibbits <jhibbits at FreeBSD.org> ---
Careful, that narrowing on powerpc and arm would yield a value of 255. If it's
used as a '< 0' check later, said check will fail.
I've run into this a lot when people set the return value of getopt() to a
char, and compare to -1, leading to an infinite loop.
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the freebsd-ppc
mailing list