Skip to content

Commit 97488ab

Browse files
committed
Merge branch 'rs/plug-strbuf-leak-in-lock-ref'
* rs/plug-strbuf-leak-in-lock-ref: refs: plug strbuf leak in lock_ref_sha1_basic()
2 parents c00e1c5 + 33adc83 commit 97488ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

refs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2334,7 +2334,7 @@ static struct ref_lock *lock_ref_sha1_basic(const char *refname,
23342334
struct strbuf err = STRBUF_INIT;
23352335
unable_to_lock_message(ref_file, errno, &err);
23362336
error("%s", err.buf);
2337-
strbuf_reset(&err);
2337+
strbuf_release(&err);
23382338
goto error_return;
23392339
}
23402340
}

0 commit comments

Comments
 (0)