* main - lvmlockd: fix missing closedir
@ 2022-12-01 18:07 David Teigland
0 siblings, 0 replies; only message in thread
From: David Teigland @ 2022-12-01 18:07 UTC (permalink / raw)
To: lvm-devel
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=55b29c1c3d4b5c1366ec0a24fb680cfb81fc4961
Commit: 55b29c1c3d4b5c1366ec0a24fb680cfb81fc4961
Parent: e63b0c7262f50ab43fcde1c50b6d880acab68407
Author: David Teigland <teigland@redhat.com>
AuthorDate: Thu Dec 1 09:53:57 2022 -0600
Committer: David Teigland <teigland@redhat.com>
CommitterDate: Thu Dec 1 09:55:11 2022 -0600
lvmlockd: fix missing closedir
in get_local_nodeid from recent lock purge feature:
lvmlockd: purge the lock resources left in previous lockspace
---
daemons/lvmlockd/lvmlockd-dlm.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/daemons/lvmlockd/lvmlockd-dlm.c b/daemons/lvmlockd/lvmlockd-dlm.c
index d262fa281..248081d0e 100644
--- a/daemons/lvmlockd/lvmlockd-dlm.c
+++ b/daemons/lvmlockd/lvmlockd-dlm.c
@@ -260,6 +260,7 @@ static int get_local_nodeid(void)
rv = sscanf(line, "%d", &val);
if (rv == 1) {
fclose(file);
+ closedir(ls_dir);
return val;
}
}
@@ -270,7 +271,7 @@ static int get_local_nodeid(void)
if (closedir(ls_dir))
log_error("get_local_nodeid closedir error");
- return rv;
+ return rv;
}
int lm_purge_locks_dlm(struct lockspace *ls)
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-12-01 18:07 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-01 18:07 main - lvmlockd: fix missing closedir David Teigland
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.