summaryrefslogtreecommitdiff
path: root/qga
diff options
context:
space:
mode:
authorJeff Cody <jcody@redhat.com>2016-03-02 11:24:42 -0500
committerJeff Cody <jcody@redhat.com>2016-03-16 13:25:29 -0400
commit03c698f0a229c8f76cfc33f0d8f755047c41f5e6 (patch)
tree672c07ee582656b398d065ccec2a7cfc35ef2199 /qga
parent0ebc03bc065329eaefb6493f5fa7df08df528f2a (diff)
downloadqemu-03c698f0a229c8f76cfc33f0d8f755047c41f5e6.tar.gz
qemu-03c698f0a229c8f76cfc33f0d8f755047c41f5e6.tar.bz2
qemu-03c698f0a229c8f76cfc33f0d8f755047c41f5e6.zip
block/sheepdog: fix argument passed to qemu_strtoul()
The function qemu_strtoul() reads 'unsigned long' sized data, which is larger than uint32_t on 64-bit machines. Even though the snap_id field in the header is 32-bits, we must accommodate the full size in qemu_strtoul(). This patch also adds more meaningful error handling to the qemu_strtoul() call, and subsequent results. Reported-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Jeff Cody <jcody@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Hitoshi Mitake <mitake.hitoshi@lab.ntt.co.jp> Message-id: e56fc50abedd9a112e0683342c8eafda063cd2f9.1456935548.git.jcody@redhat.com
Diffstat (limited to 'qga')
0 files changed, 0 insertions, 0 deletions