summaryrefslogtreecommitdiff
path: root/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'dir.c')
-rw-r--r--dir.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/dir.c b/dir.c
index 7b91501255..6564a929ff 100644
--- a/dir.c
+++ b/dir.c
@@ -375,6 +375,8 @@ static enum directory_treatment treat_directory(struct dir_struct *dir,
return recurse_into_directory;
case index_gitdir:
+ if (dir->show_other_directories)
+ return ignore_directory;
return show_directory;
case index_nonexistent: