git_config_rename_section_in_file(): avoid resource leak
commit4db7dbdb4ae5426ab133b3844ea2a6889c6897d7
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Thu, 4 May 2017 13:55:41 +0000 (4 15:55 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 8 May 2017 03:18:19 +0000 (8 12:18 +0900)
treecbe97e36732a0e6bfb874b2cd0027ee2ba87f0fe
parent5748693b9123f55363211d18e8074db5e1b8384e
git_config_rename_section_in_file(): avoid resource leak

In case of errors, we really want the file descriptor to be closed.

Discovered by a Coverity scan.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
config.c