fix exit codes (1 on error, 0 on success)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18705 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
+3
-3
@@ -20,7 +20,7 @@ usage(const char *programName)
|
||||
|
||||
printf("usage: %s [-f] <path to volume>\n"
|
||||
"\t-f\tforces unmounting in case of open files left\n", programName);
|
||||
exit(0);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ main(int argc, char **argv)
|
||||
|
||||
if (stat(path, &pathStat) < 0) {
|
||||
fprintf(stderr, "%s: The path \"%s\" is not accessible\n", programName, path);
|
||||
return -1;
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* do the work */
|
||||
@@ -68,7 +68,7 @@ main(int argc, char **argv)
|
||||
status = fs_unmount_volume(path, flags);
|
||||
if (status != B_OK) {
|
||||
fprintf(stderr, "%s: unmounting failed: %s\n", programName, strerror(status));
|
||||
return -1;
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user