On Fri, May 11, 2012 at 06:54:32PM +0400, Andrey Chernov wrote:
> Thanks, but in this two places old errno value should be saved across
> free() because free() may damage it:
I do not agree. free() cannot change errno.

> 
> On Fri, May 11, 2012 at 11:29:08AM +0000, Konstantin Belousov wrote:
> ...
> > +                   if (lstat(resolved, &sb) != 0) {
> > +                           if (m)
> > +                                   free(resolved);
> > +
>                               return (NULL);
> ...
> > +                           errno = ENOTDIR;
> >                     if (m)
> >                             free(resolved);
> >                     return (NULL);
> 

Attachment: pgpLzo9PAV9Sl.pgp
Description: PGP signature

Reply via email to