summaryrefslogtreecommitdiff
path: root/git-compat-util.h
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2016-01-06 13:09:43 (GMT)
committerJunio C Hamano <gitster@pobox.com>2016-01-07 21:52:55 (GMT)
commit79d7582e32ca84eacf032298c8ae3d26816f48d0 (patch)
tree370b19ccf775725f0a2a28e21e7443b330dffe1a /git-compat-util.h
parent833e48259e23aea76f3765d28d1b2200332301f7 (diff)
downloadgit-79d7582e32ca84eacf032298c8ae3d26816f48d0.zip
git-79d7582e32ca84eacf032298c8ae3d26816f48d0.tar.gz
git-79d7582e32ca84eacf032298c8ae3d26816f48d0.tar.bz2
commit: allow editing the commit message even in shared repos
It was pointed out by Yaroslav Halchenko that the file containing the commit message is writable only by the owner, which means that we have to rewrite it from scratch in a shared repository. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-compat-util.h')
-rw-r--r--git-compat-util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/git-compat-util.h b/git-compat-util.h
index 0feeae2..d98f3af 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -733,6 +733,7 @@ extern int xmkstemp_mode(char *template, int mode);
extern int odb_mkstemp(char *template, size_t limit, const char *pattern);
extern int odb_pack_keep(char *name, size_t namesz, const unsigned char *sha1);
extern char *xgetcwd(void);
+extern FILE *fopen_for_writing(const char *path);
#define REALLOC_ARRAY(x, alloc) (x) = xrealloc((x), (alloc) * sizeof(*(x)))