summaryrefslogtreecommitdiff
path: root/nsswitch/libwbclient/wbc_sid.c
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-01-23 19:38:28 +0100
committerVolker Lendecke <vl@samba.org>2010-01-24 14:52:33 +0100
commit96b12e0d59b27913e915ea28b3edaa7023b765c5 (patch)
treee6357b5fd596d55907fb22b4b082c8706572ba39 /nsswitch/libwbclient/wbc_sid.c
parent5a313731f3960120c08a06f2c9e9f6ea56ed9f6f (diff)
downloadsamba-96b12e0d59b27913e915ea28b3edaa7023b765c5.tar.gz
samba-96b12e0d59b27913e915ea28b3edaa7023b765c5.tar.bz2
samba-96b12e0d59b27913e915ea28b3edaa7023b765c5.zip
libwbclient: Use winbindd_free_response()
Diffstat (limited to 'nsswitch/libwbclient/wbc_sid.c')
-rw-r--r--nsswitch/libwbclient/wbc_sid.c22
1 files changed, 6 insertions, 16 deletions
diff --git a/nsswitch/libwbclient/wbc_sid.c b/nsswitch/libwbclient/wbc_sid.c
index 99c9d8e152..7aab04b86f 100644
--- a/nsswitch/libwbclient/wbc_sid.c
+++ b/nsswitch/libwbclient/wbc_sid.c
@@ -24,7 +24,7 @@
#include "replace.h"
#include "libwbclient.h"
-
+#include "../winbind_client.h"
/* Convert a binary SID to a character string */
wbcErr wbcSidToString(const struct wbcDomainSid *sid,
@@ -396,9 +396,7 @@ wbcErr wbcLookupRids(struct wbcDomainSid *dom_sid,
wbc_status = WBC_ERR_SUCCESS;
done:
- if (response.extra_data.data) {
- free(response.extra_data.data);
- }
+ winbindd_free_response(&response);
if (WBC_ERROR_IS_OK(wbc_status)) {
*pp_domain_name = domain_name;
@@ -486,9 +484,7 @@ wbcErr wbcLookupUserSids(const struct wbcDomainSid *user_sid,
wbc_status = WBC_ERR_SUCCESS;
done:
- if (response.extra_data.data) {
- free(response.extra_data.data);
- }
+ winbindd_free_response(&response);
if (sids) {
talloc_free(sids);
}
@@ -624,9 +620,7 @@ wbcErr wbcGetSidAliases(const struct wbcDomainSid *dom_sid,
if (extra_data) {
talloc_free(extra_data);
}
- if (response.extra_data.data) {
- free(response.extra_data.data);
- }
+ winbindd_free_response(&response);
if (rids) {
talloc_free(rids);
}
@@ -694,9 +688,7 @@ wbcErr wbcListUsers(const char *domain_name,
wbc_status = WBC_ERR_SUCCESS;
done:
- if (response.extra_data.data) {
- free(response.extra_data.data);
- }
+ winbindd_free_response(&response);
if (users) {
talloc_free(users);
}
@@ -762,9 +754,7 @@ wbcErr wbcListGroups(const char *domain_name,
wbc_status = WBC_ERR_SUCCESS;
done:
- if (response.extra_data.data) {
- free(response.extra_data.data);
- }
+ winbindd_free_response(&response);
if (groups) {
talloc_free(groups);
}