diff options
Diffstat (limited to 'block/rbd.c')
-rw-r--r-- | block/rbd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/block/rbd.c b/block/rbd.c index 6471f4f..fbf3059 100644 --- a/block/rbd.c +++ b/block/rbd.c @@ -916,13 +916,14 @@ static int64_t qemu_rbd_getlength(BlockDriverState *bs) return info.size; } -static int qemu_rbd_truncate(BlockDriverState *bs, int64_t offset) +static int qemu_rbd_truncate(BlockDriverState *bs, int64_t offset, Error **errp) { BDRVRBDState *s = bs->opaque; int r; r = rbd_resize(s->image, offset); if (r < 0) { + error_setg_errno(errp, -r, "Failed to resize file"); return r; } |