diff options
Diffstat (limited to 'tree.c')
-rw-r--r-- | tree.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -127,10 +127,8 @@ static int tree_scan(struct tree *tree, tree_filter_t filter, bool follow) int ret = 0; dir = opendir(tree->path); - if (!dir) { - printf("error: unable to open directory %s\n", tree->path); + if (!dir) return -1; - } while (!readdir_r(dir, &dirent, &direntp)) { |