Fail straight away rather than recursively printing error messages :)
authorGlenn L McGrath <bug1@ihug.co.nz>
Sat, 28 Sep 2002 08:30:47 +0000 (08:30 -0000)
committerGlenn L McGrath <bug1@ihug.co.nz>
Sat, 28 Sep 2002 08:30:47 +0000 (08:30 -0000)
libbb/make_directory.c

index 2a2788b68fad50f65124163db2639ffd6884a8ca..3f81d9ac2ba9d1eb87bb00bfb8603ef53014ebae 100644 (file)
@@ -61,7 +61,7 @@ int make_directory (char *path, long mode, int flags)
                if ((flags == FILEUTILS_RECUR) && (errno == EEXIST)) {
                        ret = 0;
                } else {
-                       perror_msg("Cannot create directory '%s'", path);
+                       perror_msg_and_die("Cannot create directory '%s'", path);
                }
        }
        return(ret);