X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=coreutils%2Fmkdir.c;h=c950847dc34bcb8b8e1d64b2c18357768a1bfc44;hb=87559829ffc79b94adcee00b64706ce78ff2f3fb;hp=04310e4c78a3e90b10f4f0700f6d6aaf7b73e2e2;hpb=3570a34de46b1f7dedd16999bb1687e2d6b55d40;p=oweals%2Fbusybox.git diff --git a/coreutils/mkdir.c b/coreutils/mkdir.c index 04310e4c7..c950847dc 100644 --- a/coreutils/mkdir.c +++ b/coreutils/mkdir.c @@ -51,7 +51,7 @@ extern int mkdir_main(int argc, char **argv) mode = 0; if (parse_mode(*(++argv), &mode) == FALSE) { errorMsg("Unknown mode: %s\n", *argv); - exit FALSE; + return EXIT_FAILURE; } /* Set the umask for this process so it doesn't * screw up whatever the user just entered. */ @@ -80,13 +80,13 @@ extern int mkdir_main(int argc, char **argv) if (strlen(*argv) > BUFSIZ - 1) { errorMsg(name_too_long); - exit FALSE; + return EXIT_FAILURE; } strcpy(buf, *argv); status = stat(buf, &statBuf); if (parentFlag == FALSE && status != -1 && errno != ENOENT) { errorMsg("%s: File exists\n", buf); - exit FALSE; + return EXIT_FAILURE; } if (parentFlag == TRUE) { strcat(buf, "/"); @@ -94,11 +94,11 @@ extern int mkdir_main(int argc, char **argv) } else { if (mkdir(buf, mode) != 0 && parentFlag == FALSE) { perror(buf); - exit FALSE; + return EXIT_FAILURE; } } argc--; argv++; } - return( TRUE); + return EXIT_SUCCESS; }