summaryrefslogtreecommitdiff
path: root/rerere.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2011-03-27 03:13:16 (GMT)
committerJunio C Hamano <gitster@pobox.com>2011-03-27 03:13:16 (GMT)
commitad7bb2f68c0b7786521173e05ef58d0f3e0db3d7 (patch)
tree9fc6b2df2743b837f774c0ce925cdad2427c4535 /rerere.c
parent54f6a8dbd65cbe6ad31a8b6b531de81009514eb3 (diff)
parent90a6464b4ad5887e4d12e660f51dabdbd5c00812 (diff)
downloadgit-ad7bb2f68c0b7786521173e05ef58d0f3e0db3d7.zip
git-ad7bb2f68c0b7786521173e05ef58d0f3e0db3d7.tar.gz
git-ad7bb2f68c0b7786521173e05ef58d0f3e0db3d7.tar.bz2
Merge branch 'jc/maint-rerere-in-workdir'
* jc/maint-rerere-in-workdir: rerere: make sure it works even in a workdir attached to a young repository
Diffstat (limited to 'rerere.c')
-rw-r--r--rerere.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/rerere.c b/rerere.c
index 22996bd..3d00a71 100644
--- a/rerere.c
+++ b/rerere.c
@@ -590,8 +590,7 @@ static int is_rerere_enabled(void)
if (rerere_enabled < 0)
return rr_cache_exists;
- if (!rr_cache_exists &&
- (mkdir(rr_cache, 0777) || adjust_shared_perm(rr_cache)))
+ if (!rr_cache_exists && mkdir_in_gitdir(rr_cache))
die("Could not create directory %s", rr_cache);
return 1;
}