Skip to contentSkip to conversation

Fix space checking during fs resize

PATCH New Daniel J Blueman 1 participant 1 message Apr 25, 2012 Btrfs file system

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix space checking during fs resize

Fix out-of-space checking, addressing a warning and potential resource leak when resizing the filesystem down while allocating blocks.

---
 fs/btrfs/relocation.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/btrfs/relocation.c +1 -1
index 017281d..cd2b46e 100644
@@ -3811,7 +3811,7 @@ restart:
 
 		ret = btrfs_block_rsv_check(rc->extent_root, rc->block_rsv, 5);
 		if (ret < 0) {
-			if (ret != -EAGAIN) {
+			if (ret != -ENOSPC) {
 				err = ret;
 				WARN_ON(1);
 				break;
Signature · 1 line
1.7.9.5