summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2013-09-05 14:22:29 +0200
committerKevin Wolf <kwolf@redhat.com>2013-09-12 10:12:47 +0200
commit015a1036a74ad29bb6916754911ce25587ff4db3 (patch)
tree46dacfeda73bb70c5a4e003619c3604355db1b8f /include
parent8023090be592514dea4975428543edd598c65fc3 (diff)
downloadqemu-015a1036a74ad29bb6916754911ce25587ff4db3.tar.gz
qemu-015a1036a74ad29bb6916754911ce25587ff4db3.tar.bz2
qemu-015a1036a74ad29bb6916754911ce25587ff4db3.zip
bdrv: Use "Error" for opening images
Add an Error ** parameter to BlockDriver.bdrv_open and BlockDriver.bdrv_file_open to allow more specific error messages. Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/block/block_int.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/block/block_int.h b/include/block/block_int.h
index e7d1766ae0..076b40aa43 100644
--- a/include/block/block_int.h
+++ b/include/block/block_int.h
@@ -80,8 +80,10 @@ struct BlockDriver {
void (*bdrv_reopen_commit)(BDRVReopenState *reopen_state);
void (*bdrv_reopen_abort)(BDRVReopenState *reopen_state);
- int (*bdrv_open)(BlockDriverState *bs, QDict *options, int flags);
- int (*bdrv_file_open)(BlockDriverState *bs, QDict *options, int flags);
+ int (*bdrv_open)(BlockDriverState *bs, QDict *options, int flags,
+ Error **errp);
+ int (*bdrv_file_open)(BlockDriverState *bs, QDict *options, int flags,
+ Error **errp);
int (*bdrv_read)(BlockDriverState *bs, int64_t sector_num,
uint8_t *buf, int nb_sectors);
int (*bdrv_write)(BlockDriverState *bs, int64_t sector_num,