Re: [Qemu-devel] [PATCH 5/6] pc-bios/s390-ccw: Clean up harmless misuse of isdigit()

2019-05-08 Thread Thomas Huth
On 18/04/2019 20.13, Markus Armbruster wrote: > Thomas Huth writes: > >> On 18/04/2019 16.53, Markus Armbruster wrote: >>> atoui() and get_index() pass char values to isdigit(). With a >>> standard isdigit(), we'd get undefined behavior when the value is >>> negative. But we're using isdigit()

Re: [Qemu-devel] [PATCH 5/6] pc-bios/s390-ccw: Clean up harmless misuse of isdigit()

2019-04-18 Thread Markus Armbruster
Thomas Huth writes: > On 18/04/2019 16.53, Markus Armbruster wrote: >> atoui() and get_index() pass char values to isdigit(). With a >> standard isdigit(), we'd get undefined behavior when the value is >> negative. But we're using isdigit() from pc-bios/s390-ccw/libc.h >> here, which behaves ni

Re: [Qemu-devel] [PATCH 5/6] pc-bios/s390-ccw: Clean up harmless misuse of isdigit()

2019-04-18 Thread Thomas Huth
On 18/04/2019 16.53, Markus Armbruster wrote: > atoui() and get_index() pass char values to isdigit(). With a > standard isdigit(), we'd get undefined behavior when the value is > negative. But we're using isdigit() from pc-bios/s390-ccw/libc.h > here, which behaves nicely. Clean up anyway, just

[Qemu-devel] [PATCH 5/6] pc-bios/s390-ccw: Clean up harmless misuse of isdigit()

2019-04-18 Thread Markus Armbruster
atoui() and get_index() pass char values to isdigit(). With a standard isdigit(), we'd get undefined behavior when the value is negative. But we're using isdigit() from pc-bios/s390-ccw/libc.h here, which behaves nicely. Clean up anyway, just to avoid setting a bad example. Cc: Christian Borntr