From 362b3786ebd1f97737783b53de056265efa9e870 Mon Sep 17 00:00:00 2001 From: Max Reitz Date: Tue, 11 Apr 2017 17:52:26 +0200 Subject: Revert "block/io: Comment out permission assertions" This reverts commit e3e0003a8f6570aba1421ef99a0b383a43371a74. This commit was necessary for the 2.9 release because we were unable to fix the underlying issue(s) in time. However, we will be for 2.10. Signed-off-by: Max Reitz Acked-by: Fam Zheng Signed-off-by: Kevin Wolf --- block.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'block.c') diff --git a/block.c b/block.c index 5db266b..ceaca44 100644 --- a/block.c +++ b/block.c @@ -3313,11 +3313,7 @@ int bdrv_truncate(BdrvChild *child, int64_t offset) BlockDriver *drv = bs->drv; int ret; - /* FIXME: Some format block drivers use this function instead of implicitly - * growing their file by writing beyond its end. - * See bdrv_aligned_pwritev() for an explanation why we currently - * cannot assert this permission in that case. */ - // assert(child->perm & BLK_PERM_RESIZE); + assert(child->perm & BLK_PERM_RESIZE); if (!drv) return -ENOMEDIUM; -- cgit v1.1