nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit ee05daab924cc80adbfb26599fc1ad6ba6197dc5
parent 74f4c37d5f3547d476b54582d1d95ee109907c01
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Sun,  2 Feb 2020 11:08:59 +0100

tweaks: do not leak a file descriptor when fdopen() fails

Diffstat:
Msrc/files.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/src/files.c b/src/files.c @@ -211,6 +211,7 @@ int write_lockfile(const char *lockfilename, const char *origfilename, bool modi if (filestream == NULL) { statusline(MILD, _("Error writing lock file %s: %s"), lockfilename, strerror(errno)); + close(fd); goto free_the_data; }