diff options
author | Stefan Beller <sbeller@google.com> | 2015-03-20 17:28:00 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2015-03-22 12:11:25 -0700 |
commit | 2d9426b049335c1a39be7ea7416094e944bfe63c (patch) | |
tree | 804bff73de68211cdea205d565cbd63abf9bf4a4 /git-p4.py | |
parent | builtin/help.c: fix memory leak (diff) | |
download | tgif-2d9426b049335c1a39be7ea7416094e944bfe63c.tar.xz |
read-cache: free cache entry in add_to_index in case of early return
This frees `ce` would be leaking in the error path.
Additionally a free is moved towards the return. This helps code
readability as we often have this pattern of freeing resources just
before return/exit and not in between the code.
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-p4.py')
0 files changed, 0 insertions, 0 deletions