summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-03-26 19:45:28 +0000
committerJeremy Allison <jra@samba.org>2002-03-26 19:45:28 +0000
commit05f214202c02c0d585787cd21652edbbf338e50c (patch)
treeb55d417836a48fb237217b26c496bc46a92ada89
parent1e894487f59a0c00347fdf28ddea892b40473a6d (diff)
downloadsamba-05f214202c02c0d585787cd21652edbbf338e50c.tar.gz
samba-05f214202c02c0d585787cd21652edbbf338e50c.tar.xz
samba-05f214202c02c0d585787cd21652edbbf338e50c.zip
Don't do a zero-length malloc (caught with dmalloc library).
Jeremy.
-rw-r--r--source/nsswitch/winbindd_group.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/nsswitch/winbindd_group.c b/source/nsswitch/winbindd_group.c
index c62ce54b591..4ef57513bb0 100644
--- a/source/nsswitch/winbindd_group.c
+++ b/source/nsswitch/winbindd_group.c
@@ -150,7 +150,7 @@ static BOOL fill_grent_mem(struct winbindd_domain *domain,
/* Allocate buffer */
- if (!buf) {
+ if (!buf && buf_len != 0) {
if (!(buf = malloc(buf_len))) {
DEBUG(1, ("out of memory\n"));
result = False;