Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
refs: release strbuf on error return in write_pseudoref()
author
Rene Scharfe
<l.s.r@web.de>
Wed, 30 Aug 2017 17:58:12 +0000
(19:58 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Wed, 6 Sep 2017 23:49:28 +0000
(08:49 +0900)
Signed-off-by: Rene Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
1f3992f
)
diff --git
a/refs.c
b/refs.c
index b0106b8162c7b8e3770e04c212abb05f1afbd0c3..d8dc86b1f5b08bb5d873a3eeb1fa3f927b18655e 100644
(file)
--- a/
refs.c
+++ b/
refs.c
@@
-612,7
+612,7
@@
static int write_pseudoref(const char *pseudoref, const unsigned char *sha1,
if (fd < 0) {
strbuf_addf(err, "could not open '%s' for writing: %s",
filename, strerror(errno));
-
return -1
;
+
goto done
;
}
if (old_sha1) {