summaryrefslogtreecommitdiff
path: root/cmds-replace.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmds-replace.c')
-rw-r--r--cmds-replace.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/cmds-replace.c b/cmds-replace.c
index 01ab77c9..645dc988 100644
--- a/cmds-replace.c
+++ b/cmds-replace.c
@@ -172,8 +172,13 @@ static int cmd_start_replace(int argc, char **argv)
fdmnt = open_path_or_dev_mnt(path, &dirstream);
if (fdmnt < 0) {
- fprintf(stderr, "ERROR: can't access \"%s\": %s\n",
- path, strerror(errno));
+ if (errno == EINVAL)
+ fprintf(stderr,
+ "ERROR: '%s' is not a mounted btrfs device\n",
+ path);
+ else
+ fprintf(stderr, "ERROR: can't access '%s': %s\n",
+ path, strerror(errno));
goto leave_with_error;
}