git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f6a34cb
)
libwbclient: Make wbcGetGroups not use talloc
author
Volker Lendecke
<vl@samba.org>
Sat, 3 Apr 2010 20:20:04 +0000
(22:20 +0200)
committer
Volker Lendecke
<vl@samba.org>
Mon, 19 Apr 2010 12:27:21 +0000
(14:27 +0200)
nsswitch/libwbclient/wbc_pwd.c
patch
|
blob
|
history
diff --git
a/nsswitch/libwbclient/wbc_pwd.c
b/nsswitch/libwbclient/wbc_pwd.c
index 86d54a0f7515da68ec9500d99da8131a9d446cbc..c7bfdb8fd88305e8a76f967b1838f85461d78591 100644
(file)
--- a/
nsswitch/libwbclient/wbc_pwd.c
+++ b/
nsswitch/libwbclient/wbc_pwd.c
@@
-599,7
+599,8
@@
wbcErr wbcGetGroups(const char *account,
&response);
BAIL_ON_WBC_ERROR(wbc_status);
- groups = talloc_array(NULL, gid_t, response.data.num_entries);
+ groups = (gid_t *)wbcAllocateMemory(
+ sizeof(gid_t), response.data.num_entries, NULL);
BAIL_ON_PTR_ERROR(groups, wbc_status);
for (i = 0; i < response.data.num_entries; i++) {
@@
-614,9
+615,6
@@
wbcErr wbcGetGroups(const char *account,
done:
winbindd_free_response(&response);
- if (groups) {
- talloc_free(groups);
- }
-
+ wbcFreeMemory(groups);
return wbc_status;
}