Changed names of functions in utility.c and all affected files, to make
compliant with the style guide. Everybody rebuild your tags file!
This commit is contained in:
8
mkdir.c
8
mkdir.c
@@ -50,7 +50,7 @@ extern int mkdir_main(int argc, char **argv)
|
||||
/* Find the specified modes */
|
||||
mode = 0;
|
||||
if (parse_mode(*(++argv), &mode) == FALSE) {
|
||||
errorMsg("Unknown mode: %s\n", *argv);
|
||||
error_msg("Unknown mode: %s\n", *argv);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
/* Set the umask for this process so it doesn't
|
||||
@@ -79,18 +79,18 @@ extern int mkdir_main(int argc, char **argv)
|
||||
char buf[BUFSIZ + 1];
|
||||
|
||||
if (strlen(*argv) > BUFSIZ - 1) {
|
||||
errorMsg(name_too_long);
|
||||
error_msg(name_too_long);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
strcpy(buf, *argv);
|
||||
status = stat(buf, &statBuf);
|
||||
if (parentFlag == FALSE && status != -1 && errno != ENOENT) {
|
||||
errorMsg("%s: File exists\n", buf);
|
||||
error_msg("%s: File exists\n", buf);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
if (parentFlag == TRUE) {
|
||||
strcat(buf, "/");
|
||||
createPath(buf, mode);
|
||||
create_path(buf, mode);
|
||||
} else {
|
||||
if (mkdir(buf, mode) != 0 && parentFlag == FALSE) {
|
||||
perror(buf);
|
||||
|
Reference in New Issue
Block a user