refs loose_lookup: also free the buffer on success

Free the ref_file buffer at the end of the function also on
success. This fixes a small memory leak.
This commit is contained in:
Carlos Martín Nieto 2011-03-22 12:47:53 +01:00 committed by Vicent Marti
parent 70236bab2d
commit 567fc1d20c

View File

@ -333,6 +333,7 @@ static int loose_lookup(
ref->mtime = ref_time;
*ref_out = ref;
gitfo_free_buf(&ref_file);
return GIT_SUCCESS;
cleanup: