summaryrefslogtreecommitdiffstats
path: root/src/providers/ldap/sdap_async_services.c
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2012-02-14 12:30:55 +0100
committerStephen Gallagher <sgallagh@redhat.com>2012-02-14 09:43:14 -0500
commit29b412285db72b0c735e8ad6cb933c029d2a27d9 (patch)
tree658a19633fcfafff1243831e8ac904a07317bb16 /src/providers/ldap/sdap_async_services.c
parent48f82b73c24d2486f10e588ebabce95873656d0e (diff)
downloadsssd-29b412285db72b0c735e8ad6cb933c029d2a27d9.tar.gz
sssd-29b412285db72b0c735e8ad6cb933c029d2a27d9.tar.xz
sssd-29b412285db72b0c735e8ad6cb933c029d2a27d9.zip
Fix memory hierarchy when processing nested group memberships
https://fedorahosted.org/sssd/ticket/1186
Diffstat (limited to 'src/providers/ldap/sdap_async_services.c')
-rw-r--r--src/providers/ldap/sdap_async_services.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/providers/ldap/sdap_async_services.c b/src/providers/ldap/sdap_async_services.c
index b472e4072..5bc044630 100644
--- a/src/providers/ldap/sdap_async_services.c
+++ b/src/providers/ldap/sdap_async_services.c
@@ -199,10 +199,10 @@ sdap_get_services_process(struct tevent_req *subreq)
}
/* Copy the new services into the list
- * They're already allocated on 'state'
*/
for (i = 0; i < count; i++) {
- state->services[state->count + i] = services[i];
+ state->services[state->count + i] =
+ talloc_steal(state->services, services[i]);
}
state->count += count;