andykimpe / rpms / 389-ds-base

Forked from rpms/389-ds-base 5 months ago
Clone
dc8c34
From c970af0ea2da634d5ee7562047715c94a4ab5c4e Mon Sep 17 00:00:00 2001
dc8c34
From: Noriko Hosoi <nhosoi@totoro.usersys.redhat.com>
dc8c34
Date: Fri, 26 Oct 2012 18:18:15 -0700
dc8c34
Subject: [PATCH 09/10] Coverity defects
dc8c34
dc8c34
History:
dc8c34
The commit b9eeb2e1a8e688dfec753e8965d0e5aeb119e638 for Ticket #481
dc8c34
"expand nested posix groups" introduced 4 coverity defects.  Commit for
dc8c34
the fixing patch e9941a2915ac848abe9a4afe802d0432aa0c354a failed to solve
dc8c34
13102: Resource leak.
dc8c34
dc8c34
Fix Description: This patch explicitly calls slapi_valueset_free for
dc8c34
the leak reported object muid_old_vs.
dc8c34
(cherry picked from commit 544f027193139a109aeb14145ae1d77c4bdcc618)
dc8c34
(cherry picked from commit 55997a627ecf155499621b17eb7e118787536765)
dc8c34
---
dc8c34
 .../plugins/posix-winsync/posix-group-func.c       |    1 +
dc8c34
 1 files changed, 1 insertions(+), 0 deletions(-)
dc8c34
dc8c34
diff --git a/ldap/servers/plugins/posix-winsync/posix-group-func.c b/ldap/servers/plugins/posix-winsync/posix-group-func.c
dc8c34
index 9ad636f..60528f5 100644
dc8c34
--- a/ldap/servers/plugins/posix-winsync/posix-group-func.c
dc8c34
+++ b/ldap/servers/plugins/posix-winsync/posix-group-func.c
dc8c34
@@ -497,6 +497,7 @@ propogateMembershipUpward(Slapi_Entry *entry, Slapi_ValueSet *muid_vs, int depth
dc8c34
                     slapi_valueset_add_value(muid_upward_vs, v);
dc8c34
                 }
dc8c34
             }
dc8c34
+            slapi_valueset_free(muid_old_vs);
dc8c34
         }
dc8c34
 
dc8c34
         /* Update this group's membership */
dc8c34
-- 
dc8c34
1.7.1
dc8c34