summaryrefslogtreecommitdiffstats
path: root/hw/display/g364fb.c
diff options
context:
space:
mode:
authorPeter Maydell2017-02-10 17:28:23 +0100
committerMax Reitz2017-02-12 00:53:31 +0100
commit8b3c67922851bee9d5420373bfea010d3648bbc4 (patch)
tree594a28cda91b7f2f176ab48264bc7a3a2293a995 /hw/display/g364fb.c
parentqemu-io: don't allow I/O operations larger than BDRV_REQUEST_MAX_BYTES (diff)
downloadqemu-8b3c67922851bee9d5420373bfea010d3648bbc4.tar.gz
qemu-8b3c67922851bee9d5420373bfea010d3648bbc4.tar.xz
qemu-8b3c67922851bee9d5420373bfea010d3648bbc4.zip
qemu-img: Use qemu_strtoul() rather than raw strtoul()
Some of the argument parsing in qemu-img uses strtoul() to parse integer arguments. This is tricky to get correct and in fact the code does not get it right, because it assigns the result of strtoul() to an 'int' variable and then tries to check for > INT_MAX. Coverity correctly complains that the comparison is always false. Rewrite to use qemu_strtoul(), which has a saner convention for reporting conversion failures. (Fixes CID 1356421, CID 1356422, CID 1356423.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1486744104-15590-2-git-send-email-peter.maydell@linaro.org Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'hw/display/g364fb.c')
0 files changed, 0 insertions, 0 deletions