Source-Changes-D archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/lib/libutil
On Mon, Dec 31, 2012 at 02:59:13AM +0100, Joerg Sonnenberger wrote:
> > Modified Files:
> > src/lib/libutil: efun.c
> >
> > Log Message:
> > If malloc, calloc, or realloc returns NULL when a size of 0 was
> > requested, which is allowed by pertinent standards, honor it instead
> > of bombing.
> >
> > Do not do this for calloc(x, y) where x != 0 && y != 0 but x*y == 0;
> > in that case bomb.
>
> The commit message is misleading. We expect calloc(x,y) to return NULL
> if x!=0 && y!=0 && x*y==0.
I don't understand. The logic I added is exactly what I described.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index