From 41caee31481d2bee0a0b44cce0e25d52fe68e9c5 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Wed, 17 Jun 2015 00:23:38 +0000 Subject: [PATCH] iscsi-scstd: Fix a file descriptor leak in an error path Detected by Coverity. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@6371 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- iscsi-scst/usr/event.c | 1 + 1 file changed, 1 insertion(+) diff --git a/iscsi-scst/usr/event.c b/iscsi-scst/usr/event.c index 719c7e2a6..2dbf387bb 100644 --- a/iscsi-scst/usr/event.c +++ b/iscsi-scst/usr/event.c @@ -1188,6 +1188,7 @@ int nl_open(void) res = nl_write(nl_fd, NULL, 0); if (res < 0) { log_error("%s %d\n", __FUNCTION__, res); + close(nl_fd); return res; }