diff options
author | Martin Ågren <martin.agren@gmail.com> | 2017-10-01 19:42:08 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-10-02 13:03:10 +0900 |
commit | 886e1084d78cda218b4d1133e8154e8556f92222 (patch) | |
tree | 2114089d84f6112c5bca73b3360fce8c820f25ab /builtin/diff.c | |
parent | Git 2.14.2 (diff) | |
download | tgif-886e1084d78cda218b4d1133e8154e8556f92222.tar.xz |
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>
Diffstat (limited to 'builtin/diff.c')
-rw-r--r-- | builtin/diff.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/builtin/diff.c b/builtin/diff.c index 7cde6abbcf..0da526cfdb 100644 --- a/builtin/diff.c +++ b/builtin/diff.c @@ -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; } |