Skip to content

Commit 9e903a5

Browse files
pks-tgitster
authored andcommitted
builtin/difftool: plug memory leaks in run_dir_diff()
We're leaking a bunch of memory leaks in `run_dir_diff()`. Plug them. Signed-off-by: Patrick Steinhardt <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent f87c55c commit 9e903a5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

builtin/difftool.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -662,6 +662,9 @@ static int run_dir_diff(const char *extcmd, int symlinks, const char *prefix,
662662

663663
free(lbase_dir);
664664
free(rbase_dir);
665+
strbuf_release(&info);
666+
strbuf_release(&lpath);
667+
strbuf_release(&rpath);
665668
strbuf_release(&ldir);
666669
strbuf_release(&rdir);
667670
strbuf_release(&wtdir);

0 commit comments

Comments
 (0)