aboutsummaryrefslogtreecommitdiff
path: root/archive-zip.c
diff options
context:
space:
mode:
Diffstat (limited to 'archive-zip.c')
-rw-r--r--archive-zip.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/archive-zip.c b/archive-zip.c
index 7c4984886..1eaf262b7 100644
--- a/archive-zip.c
+++ b/archive-zip.c
@@ -182,10 +182,10 @@ static int write_zip_entry(const unsigned char *sha1,
goto out;
}
- if (S_ISDIR(mode)) {
+ if (S_ISDIR(mode) || S_ISDIRLNK(mode)) {
method = 0;
attr2 = 16;
- result = READ_TREE_RECURSIVE;
+ result = (S_ISDIR(mode) ? READ_TREE_RECURSIVE : 0);
out = NULL;
uncompressed_size = 0;
compressed_size = 0;