This is the mail archive of the libc-alpha@sources.redhat.com 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: I: [PATCH] asprintf error handling fix


"Dmitry V. Levin" <ldv@alt-linux.org> writes:

> - When _IO_vfprintf call fails, _IO_vasprintf returns error code without
>   freeing memory allocated before (either in this function or during
>   _IO_vfprintf execution).

OK, I've changed that.  Slightly different, though.

> - When either malloc or _IO_vfprintf call fails, _IO_vasprintf returns
>   error code without setting result_ptr to zero.

That's nonsense.  The code never did this and there is no reason to
ever do this.

> You may ask why asprintf should zero result_ptr in case of error?

And all bogus.

-- 
---------------.                          ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Red Hat          `--' drepper at redhat.com   `------------------------


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