summaryrefslogtreecommitdiff
path: root/cmds-replace.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmds-replace.c')
-rw-r--r--cmds-replace.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/cmds-replace.c b/cmds-replace.c
index c777f1c9..a980305e 100644
--- a/cmds-replace.c
+++ b/cmds-replace.c
@@ -330,6 +330,7 @@ static int cmd_replace_start(int argc, char **argv)
}
}
close_file_or_dir(fdmnt, dirstream);
+ btrfs_close_all_devices();
return 0;
leave_with_error:
@@ -339,6 +340,7 @@ leave_with_error:
close(fdmnt);
if (fddstdev != -1)
close(fddstdev);
+ btrfs_close_all_devices();
return 1;
}