diff options
Diffstat (limited to 'file_io/unix')
-rw-r--r-- | file_io/unix/dir.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/file_io/unix/dir.c b/file_io/unix/dir.c index eed7f3a41..849e89d7e 100644 --- a/file_io/unix/dir.c +++ b/file_io/unix/dir.c @@ -312,6 +312,11 @@ apr_status_t apr_dir_make_recursive(const char *path, apr_fileperms_t perm, char *dir; dir = path_remove_last_component(path, pool); + /* If there is no path left, give up. */ + if (dir[0] == '\0') { + return apr_err; + } + apr_err = apr_dir_make_recursive(dir, perm, pool); if (!apr_err) |