Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 94eec0fc authored by Theodore Ts'o's avatar Theodore Ts'o
Browse files

ext4: fix retry handling in ext4_ext_truncate()



We tested for ENOMEM instead of -ENOMEM.   Oops.

Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
Cc: stable@vger.kernel.org
parent dd12ed14
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4412,7 +4412,7 @@ void ext4_ext_truncate(handle_t *handle, struct inode *inode)
retry:
	err = ext4_es_remove_extent(inode, last_block,
				    EXT_MAX_BLOCKS - last_block);
	if (err == ENOMEM) {
	if (err == -ENOMEM) {
		cond_resched();
		congestion_wait(BLK_RW_ASYNC, HZ/50);
		goto retry;