commands/umount: Return real error code if "umount" fail
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
2c8c0f3488
commit
0792c77373
|
@ -23,16 +23,10 @@
|
|||
|
||||
static int do_umount(int argc, char *argv[])
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
if (argc != 2)
|
||||
return COMMAND_ERROR_USAGE;
|
||||
|
||||
if ((ret = umount(argv[1]))) {
|
||||
perror("umount");
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
return umount(argv[1]);
|
||||
}
|
||||
|
||||
static const __maybe_unused char cmd_umount_help[] =
|
||||
|
|
Loading…
Reference in New Issue