]> git.proxmox.com Git - mirror_qemu.git/commit - hw/sparc/leon3.c
hw/sparc/leon3: Don't call get_image_size() on a NULL pointer
authorPeter Maydell <peter.maydell@linaro.org>
Fri, 5 Aug 2016 10:03:59 +0000 (11:03 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Mon, 8 Aug 2016 12:58:42 +0000 (13:58 +0100)
commit47dc0ec576c3d8748985e34d273c8dc0465c5ddb
tree8f5d995ce46474c67d5626c2810959fa04705fa5
parentf5edfcfafbc0fbe2e2270b9fbcbf9009399bc27a
hw/sparc/leon3: Don't call get_image_size() on a NULL pointer

get_image_size() doesn't handle being passed a NULL pointer, so
avoid doing that. Spotted by the clang ub sanitizer (which notices
the attempt to pass NULL to open()).

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 1470391439-28427-1-git-send-email-peter.maydell@linaro.org
hw/sparc/leon3.c