[PATCH] Btrfs-progs: bugfix: bail out when check_mounted_where returns an error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Jan Schmidt <list.btrfs@xxxxxxxxxxxxx>
---
 scrub.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/scrub.c b/scrub.c
index 22052ed..8270431 100644
--- a/scrub.c
+++ b/scrub.c
@@ -942,6 +942,8 @@ static int scrub_fs_info(int fd, char *path,
 		                          &fs_devices_mnt);
 		if (!ret)
 			return -EINVAL;
+		if (ret < 0)
+			return ret;
 		fi_args->num_devices = 1;
 		fi_args->max_id = fs_devices_mnt->latest_devid;
 		i = fs_devices_mnt->latest_devid;
-- 
1.7.3.4

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux