From: "Jeff Trawick" <[EMAIL PROTECTED]>
Sent: Monday, April 30, 2001 9:46 AM


> Help me out here... I don't follow your comments.
> 
> "William A. Rowe, Jr." <[EMAIL PROTECTED]> writes:
> 
> > Jeff,
> > 
> >   this is the wrong solution (and it was anticipated).  Since win32 and OS2 
> > don't
> > need the unix MPM's they were never fixed, apparently (from this
> > report) they must be.
> 
> what is the connection between "unix MPM" and this code?  Do you mean
> "unix build of APR?"

We implemented a wrapper apr_get_netos_error() around the win32 and os2 
pseudo-h_errno info.
Didn't need to update unix MPMs to use it (nor the unix-specific APR code) 
since neither
platform actually the unix MPMs.  In hindsite we should have.

> >   We can't go munging system symbols, see the declarations in apr_errno.h 
> > for the
> > apr_get_netos_error() (and if we need it, we could implement an 
> > apr_set_netos_error() 
> > although it may not enjoy cross-platform support!)
> 
> What does "munging system symbols" mean?

It seemed you were about to redeclare some stuff.  My bad, I misunderstood your 
patch.
> apr_get/set_netos_error() is not sufficient.  For Unix that needs to deal
> with errno.  This is h_errno.



Either way, we don't want platform crisscrossed #if blocks when you can add an 
apr_get_netos_error() macro implementation with that same condition.  netos 
corresponds
to h_errno, not errno :-)

> >   Patch the apr core and mpms to adopt this call instead of h_errno and 
> > implement your
> > solution in terms of declaring apr_get_netos_error() and the problem
> > should go away.
> 
> can't do because of the errno/h_errno issue...

If a platform uses errno to return the h_errno class of errors, then 
apr_get_netos_error 
would simply return errno.  Most platforms appear to have a different sockets 
error store.

> Note that this path is only used on systems with getnameinfo() and IPv6
> support.  The h_errno kludge helps out with some getnameinfo() issues
> on common versions of glibc.  Before we truly clean up this code we
> need to understand what is needed to operate with getnameinfo() across
> a variety of systems.  Hopefully the h_errno stuff can then be hidden
> inside ifdef GETNAMEINFO_SETS_H_ERRNO and any non-Unix platforms which
> later add getnameinfo() support won't be hurt by the kludge since it
> won't be set.

I'm suggesting the 'kluge' goes away and this can be done consistently across 
platforms.

Reply via email to