From 2990befa4cf9219f33b21b6c50d3e2afa4b7461b Mon Sep 17 00:00:00 2001 From: Poornima Date: Thu, 14 Nov 2013 01:29:30 +0000 Subject: gfapi: Closed the logfile fd in glfs_fini The logfile fd is not closed even after calling glfs_fini, hence in smb mount if connection to glusterfs volume fails at a point after the log file was opened, the fd would remain open until the process dies. This patch closes the logfile fd in glfs_fini. Change-Id: I608bfac9c6833b42750b0383ad26fd33ee378ee1 BUG: 1030228 Signed-off-by: Poornima Reviewed-on: http://review.gluster.org/6263 Tested-by: Gluster Build System Reviewed-by: Anand Avati --- api/src/glfs.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'api/src/glfs.c') diff --git a/api/src/glfs.c b/api/src/glfs.c index e94419c2d57..29ed47c0c61 100644 --- a/api/src/glfs.c +++ b/api/src/glfs.c @@ -666,5 +666,8 @@ glfs_fini (struct glfs *fs) glfs_subvol_done (fs, subvol); + if (ctx->log.logfile) + fclose (ctx->log.logfile); + return ret; } -- cgit