|
|
|
@ -66,7 +66,7 @@ static char *mufs_abspath(const char *path) |
|
|
|
|
return s; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
static struct mufs_dir *mufs_opendir2(struct mufs *fs, struct mufs_dirent *entry) |
|
|
|
|
static struct mufs_dir *mufs_opendirent(struct mufs *fs, struct mufs_dirent *entry) |
|
|
|
|
{ |
|
|
|
|
struct mufs_dir *dir; |
|
|
|
|
|
|
|
|
@ -109,7 +109,7 @@ static struct mufs_tree *resolve_path(struct mufs *fs, const char *path) |
|
|
|
|
if (strcmp(s, "/") == 0) |
|
|
|
|
return &fs->root; |
|
|
|
|
|
|
|
|
|
if (!(dir = mufs_opendir2(fs, NULL))) |
|
|
|
|
if (!(dir = mufs_opendirent(fs, NULL))) |
|
|
|
|
goto err_free_s; |
|
|
|
|
|
|
|
|
|
for (p = s + 1; *p != '\0'; p = end) { |
|
|
|
@ -124,7 +124,7 @@ static struct mufs_tree *resolve_path(struct mufs *fs, const char *path) |
|
|
|
|
|
|
|
|
|
mufs_closedir(dir); |
|
|
|
|
|
|
|
|
|
if (!(dir = mufs_opendir2(fs, &entry))) |
|
|
|
|
if (!(dir = mufs_opendirent(fs, &entry))) |
|
|
|
|
goto err_free_s; |
|
|
|
|
|
|
|
|
|
break; |
|
|
|
|