This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PING][PATCH] Use NSS_STATUS_TRYAGAIN to indicate insufficient buffer (BZ #16878)
- From: OndÅej BÃlka <neleai at seznam dot cz>
- To: Siddhesh Poyarekar <siddhesh at redhat dot com>
- Cc: libc-alpha at sourceware dot org, m dot weiser at science-computing dot de
- Date: Fri, 23 May 2014 15:06:38 +0200
- Subject: Re: [PING][PATCH] Use NSS_STATUS_TRYAGAIN to indicate insufficient buffer (BZ #16878)
- Authentication-results: sourceware.org; auth=none
- References: <20140430091330 dot GV10922 at spoyarek dot pnq dot redhat dot com> <20140515084231 dot GF32387 at spoyarek dot pnq dot redhat dot com>
On Thu, May 15, 2014 at 02:12:32PM +0530, Siddhesh Poyarekar wrote:
> Ping!
>
> On Wed, Apr 30, 2014 at 02:43:30PM +0530, Siddhesh Poyarekar wrote:
> > The netgroups nss modules in the glibc tree use NSS_STATUS_UNAVAIL
> > (with errno as ERANGE) when the supplied buffer does not have
> > sufficient space for the result. This is wrong, because the canonical
> > way to indicate insufficient buffer is to set the errno to ERANGE and
> > the status to NSS_STATUS_TRYAGAIN, as is used by all other modules.
> >
> > This fixes nscd behaviour when the nss_ldap module returns
> > NSS_STATUS_TRYAGAIN to indicate that a netgroup entry is too long to
> > fit into the supplied buffer. A reproducer is present on the bz
> > #16878, which I used to verify that the problem is fixed. Many thanks
> > to Michael Weiser for the reproducer and analysis.
> >
looks ok.