From: Ulrich Drepper Date: Fri, 1 Oct 2004 21:35:08 +0000 (+0000) Subject: (__nscd_getgrouplist): Add assert. X-Git-Tag: cvs/fedora-glibc-20041004T0747~14 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f7fa2b1951287b71711228e1fa6ddf97982f1efd;p=platform%2Fupstream%2Fglibc.git (__nscd_getgrouplist): Add assert. --- diff --git a/nscd/nscd_initgroups.c b/nscd/nscd_initgroups.c index d6cb000..3e4d926 100644 --- a/nscd/nscd_initgroups.c +++ b/nscd/nscd_initgroups.c @@ -128,8 +128,12 @@ __nscd_getgrouplist (const char *user, gid_t group, long int *size, } } else - /* No group found yet. */ - retval = 0; + { + /* No group found yet. */ + retval = 0; + + assert (*size >= 1); + } /* Check whether GROUP is part of the mix. If not, add it. */ if (retval >= 0)