On Fri, 9 Feb 2007 11:03:49 +0100
Simon Vallet <svallet@genoscope.cns.fr> wrote:
> So it seems an alloc is failing somewhere... I'll try to confirm this
> and get back to you.
Yup -- the following returns a null pointer due to rrset->rri_nsigs
being 0 :
rrset->rri_sigs = calloc(rrset->rri_nsigs, sizeof(struct rdatainfo));
This is what POSIX has to say on the subject:
"If the size of the space requested is 0, the behavior is
implementation-defined: the value returned shall be either a null
pointer or a unique pointer."
I don't know how other OSes implement it, but checking for the presence
of SIG records somewhere might be good idea.
Simon
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@mindrot.org
http://lists.mindrot.org/mailman/listinfo/openssh-unix-dev
|