[PATCH 0/2] Don't make $GIT_DIR executable
- From
Michael Haggerty <mhagger@alum.mit.edu>
- Date
- Nov 15, 2014, 07:26 UTC
- Message-ID
- <1416036379-4994-1-git-send-email-mhagger@alum.mit.edu>
Starting with v2.1.0, "git init" creates $GIT_DIR/config with its u+x bit set. These two patches are "belt and suspenders"--either one would fix the bug, but IMO it makes sense to apply both of them. Plus, the second patch will help repair repositories that were created while this bug was in the wild.
I think these patches should go into "maint". They apply cleanly there. When merging forward to master, there are two conflicts in config.c which can be resolved by
s/lock->filename/lock->filename.buf/
in two places.
Michael Haggerty (2): create_default_files(): don't set u+x bit on $GIT_DIR/config config: clear the executable bits (if any) on $GIT_DIR/config
builtin/init-db.c | 1 + config.c | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-)
-- 2.1.1