diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2017-07-09 22:07:17 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2017-07-18 15:14:35 +0200 |
commit | cfc87e00c22ab4ea0262c9771c803ed03d754001 (patch) | |
tree | 66e44f75ce2db3579d9ff5704801e3ad54974224 /include/sysemu | |
parent | 9877860e7bd1e26ee70ab9bb5ebc34c92bf23bf5 (diff) | |
download | qemu-cfc87e00c22ab4ea0262c9771c803ed03d754001.zip qemu-cfc87e00c22ab4ea0262c9771c803ed03d754001.tar.gz qemu-cfc87e00c22ab4ea0262c9771c803ed03d754001.tar.bz2 |
block/vpc.c: Handle write failures in get_image_offset()
Coverity (CID 1355236) points out that get_image_offset() doesn't check that
it actually succeeded in writing the updated block bitmap to the file.
Check the error return from bdrv_pwrite_sync() and propagate an error
response back up to the function which calls get_image_offset() for
a write so that it can return the error to its caller.
get_sector_offset() is only used for reads, but we move it to the
same API for consistency.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'include/sysemu')
0 files changed, 0 insertions, 0 deletions