diff mbox

[1/2] btrfs-progs: remove BUG_ON on num of devices for btrfs fi show

Message ID 1415326063-8838-2-git-send-email-guihc.fnst@cn.fujitsu.com (mailing list archive)
State Accepted
Headers show

Commit Message

Gui Hecheng Nov. 7, 2014, 2:07 a.m. UTC
The following BUG_ON:
	BUG_ON(ndevs >= fi_args->num_devices)
is not needed, because it always fails with seed devices present.

Signed-off-by: Gui Hecheng <guihc.fnst@cn.fujitsu.com>
---
 utils.c | 1 -
 1 file changed, 1 deletion(-)
diff mbox

Patch

diff --git a/utils.c b/utils.c
index f10c178..9bcc1a0 100644
--- a/utils.c
+++ b/utils.c
@@ -1889,7 +1889,6 @@  int get_fs_info(char *path, struct btrfs_ioctl_fs_info_args *fi_args,
 	i++;
 
 	for (; i <= fi_args->max_id; ++i) {
-		BUG_ON(ndevs >= fi_args->num_devices);
 		ret = get_device_info(fd, i, &di_args[ndevs]);
 		if (ret == -ENODEV)
 			continue;