summaryrefslogtreecommitdiff
path: root/support/nfsidmap/nss.c
diff options
context:
space:
mode:
Diffstat (limited to 'support/nfsidmap/nss.c')
-rw-r--r--support/nfsidmap/nss.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/support/nfsidmap/nss.c b/support/nfsidmap/nss.c
index 9d46499..669760b 100644
--- a/support/nfsidmap/nss.c
+++ b/support/nfsidmap/nss.c
@@ -467,6 +467,17 @@ static int nss_plugin_init(void)
return 0;
}
+/*
+ * Called by dlclose(). See dlopen(3) man page
+ */
+__attribute__((destructor))
+static int nss_plugin_term(void)
+{
+ free_local_realms();
+ conf_cleanup();
+ return 0;
+}
+
struct trans_func nss_trans = {
.name = "nsswitch",