summaryrefslogtreecommitdiff
path: root/ref-filter.h
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2017-05-04 13:58:42 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-05-08 03:18:20 (GMT)
commit5026b471751092ab971f3d4ae46320bc8ce40ff5 (patch)
tree56917f1973c1e3f89ca6ed3919b53fb33c25e3a5 /ref-filter.h
parent7c565a6b2d8bf7fe989c85dc75df7fabc8113f40 (diff)
downloadgit-5026b471751092ab971f3d4ae46320bc8ce40ff5.zip
git-5026b471751092ab971f3d4ae46320bc8ce40ff5.tar.gz
git-5026b471751092ab971f3d4ae46320bc8ce40ff5.tar.bz2
add_reflog_for_walk: avoid memory leak
We free()d the `log` buffer when dwim_log() returned 1, but not when it returned a larger value (which meant that it still allocated the buffer but we simply ignored it). While in the vicinity, make sure that the `reflogs` structure as well as the `branch` variable are released properly, too. Identified by Coverity. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'ref-filter.h')
0 files changed, 0 insertions, 0 deletions