This is the mail archive of the
mailing list for the glibc project.
Re: [PATCH] Allocation buffers for NSS result construction
- From: DJ Delorie <dj at redhat dot com>
- To: Florian Weimer <fweimer at redhat dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Fri, 16 Jun 2017 17:29:44 -0400
- Subject: Re: [PATCH] Allocation buffers for NSS result construction
- Authentication-results: sourceware.org; auth=none
- Authentication-results: ext-mx05.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com
- Authentication-results: ext-mx05.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=dj at redhat dot com
- Dkim-filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 849813345A3
- Dmarc-filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 849813345A3
Florian Weimer <firstname.lastname@example.org> writes:
> I think you'll have to keep a NULL check in it because this use case is
> quite obscure.
True, but I was suggesting you handle the obscure case in a useful way
to keep your module robust.
And COPY_IF_ROOM is only half the code; the other half generates the
list of pointers that preceeds it - see copy_group() in my patch.
If your code doesn't have a way to generate a *list* of strings, one of
which may be NULL, I have to code the whole thing myself anyway.