httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <>
Subject Re: Spurious return from select()
Date Thu, 09 Aug 2001 19:12:23 GMT
Shail Bhatnagar <> writes:

> Jeff, Thanks for your response. I am 
> using the standard child_main() loop
> in which select() is protected by the
> mutex. The only difference is that the
> parent is bound to a well known udp
> port and so all children are monitoring
> this well known port. Despite this mutex,
> I see this behavior fairly consistently.
> The frequency is more on solaris than on linux.

you are calling recvfrom() while still holding the accept mutex,

no other idea...

> The crash that I saw was in apr_pool_alloc_init().
> apr_lock_create() failed, although there were
> not permissions problems and then apr_lock_destroy()
> crashed while accessing a NULL pointer.
> The relevant code fragment in apr_pool_alloc_init() is :
>     status = apr_lock_create(&alloc_mutex, APR_MUTEX, APR_INTRAPROCESS,
>                    NULL, globalp);
>     if (status != APR_SUCCESS) {
>         apr_lock_destroy(alloc_mutex);
>         return status;
>     }

well, clearly apr_lock_destroy() shouldn't be called if the mutex
wasn't successfully created... I'll commit a fix in a jiffy

the question most interesting to me is why this apr_lock_create()
failing for you and for noone else...  (I guess it just happened

if you can manage to recreate, please run truss/strace on the program
so we can see what syscall is failing, and with what errno

Jeff Trawick | | PGP public key at web site:
             Born in Roswell... married an alien...

View raw message