aboutsummaryrefslogtreecommitdiff
path: root/fast-import.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-01-13 23:10:50 -0800
committerJunio C Hamano <gitster@pobox.com>2009-01-13 23:10:50 -0800
commit4f8b8992ef0c009822cdca18d32ddf3a124ee284 (patch)
treed6688aedd217cdd9f46962af57432265e9b5ccff /fast-import.c
parent885a1ffb936cb8e32a15413a9a2404a4b4200f62 (diff)
parent3d1d81eba29d5cfc5b214dc049b743ffbe032ef4 (diff)
downloadgit-4f8b8992ef0c009822cdca18d32ddf3a124ee284.tar.gz
git-4f8b8992ef0c009822cdca18d32ddf3a124ee284.tar.xz
Merge branch 'maint-1.6.0' into maint
* maint-1.6.0: fast-import: Cleanup mode setting. Git.pm: call Error::Simple() properly
Diffstat (limited to 'fast-import.c')
-rw-r--r--fast-import.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fast-import.c b/fast-import.c
index a6bce6619..f0e08aca7 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -1872,12 +1872,13 @@ static void file_change_m(struct branch *b)
if (!p)
die("Corrupt mode: %s", command_buf.buf);
switch (mode) {
+ case 0644:
+ case 0755:
+ mode |= S_IFREG;
case S_IFREG | 0644:
case S_IFREG | 0755:
case S_IFLNK:
case S_IFGITLINK:
- case 0644:
- case 0755:
/* ok */
break;
default:
@@ -1944,7 +1945,7 @@ static void file_change_m(struct branch *b)
typename(type), command_buf.buf);
}
- tree_content_set(&b->branch_tree, p, sha1, S_IFREG | mode, NULL);
+ tree_content_set(&b->branch_tree, p, sha1, mode, NULL);
}
static void file_change_d(struct branch *b)