This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Allocation buffers for NSS result construction


I have no specific comments on this, it looks pretty good and I like the
idea of centralizing this (I just did something similar in the NSS
testsuite, could have used this).  I mostly focused on the allocation
routines; I'm not familiar with resolv yet.

I do worry about having "internal" (internal to the allocator, not
internal to glibc) functions in a header.  They're written as if they'll
never be called by "outsiders" (i.e. little argument checking) but
there's no protection against such calls.  I don't know how to add such
protection, though.

Not having a pointer to the buffer's beginning irked me a bit, but I
don't see any reason to include it anyway.

I would recommend a few comments defining the behavior if NULL is passed
as a thing to copy - the NSS testsuite needed to preserve such
"mistakes" in the test data.

I wonder if this new functionality is complex enough to warrant a
separate bit of documentation?  Either in the manual or elsewhere...

The reallocarray patch also includes a __check_mul_overflow_size_t style
function; this duplication will need to be resolved as patches get
committed.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]