builtin/: add UNLEAKs
Add some UNLEAKs where we are about to return from `cmd_*`. UNLEAK the variables in the same order as we've declared them. While addressing `msg` in builtin/tag.c, convert the existing `strbuf_release()` calls as well. Signed-off-by: Martin Ågren <martin.agren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
4010f1d1b7
commit
886e1084d7
@ -466,5 +466,8 @@ int cmd_diff(int argc, const char **argv, const char *prefix)
|
||||
result = diff_result_code(&rev.diffopt, result);
|
||||
if (1 < rev.diffopt.skip_stat_unmatch)
|
||||
refresh_index_quietly();
|
||||
UNLEAK(rev);
|
||||
UNLEAK(ent);
|
||||
UNLEAK(blob);
|
||||
return result;
|
||||
}
|
||||
|
Reference in New Issue
Block a user