summaryrefslogtreecommitdiff
path: root/xdiff
diff options
context:
space:
mode:
authorJonathan Nieder <jrnieder@gmail.com>2010-10-04 04:34:27 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-10-06 17:46:05 (GMT)
commit9173912be36c4f967f42f176be767fc5ba3c4077 (patch)
tree013bd62b59f7b4ce95a00f8d7424a5d47ceefde3 /xdiff
parent95ae69b95ba595d884d31a5cee92a823ec0c705f (diff)
downloadgit-9173912be36c4f967f42f176be767fc5ba3c4077.zip
git-9173912be36c4f967f42f176be767fc5ba3c4077.tar.gz
git-9173912be36c4f967f42f176be767fc5ba3c4077.tar.bz2
init: plug tiny one-time memory leak
The buffer used to construct paths like ".git/objects/info" and ".git/objects/pack" is allocated on the heap and never freed. So free it. While at it, factor out the relevant code into its own function and rename the sha1_dir variable to object_directory (to match the change in everyday usage after the renaming of SHA1_FILE_DIRECTORY in v0.99~603^2~7, 2005). Noticed by valgrind while setting up tests (in test-lib). Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'xdiff')
0 files changed, 0 insertions, 0 deletions