apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject Re: cvs commit: apr/memory/unix apr_pools.c
Date Fri, 14 Dec 2001 20:48:54 GMT
Justin Erenkrantz <jerenkrantz@ebuilt.com> writes:

> On Fri, Dec 14, 2001 at 08:14:10PM -0000, trawick@apache.org wrote:
> >   @@ -124,7 +124,11 @@
> >    
> >    struct allocator_t {
> >        apr_uint32_t        max_index;
> >   +#if APR_HAS_THREADS
> >        apr_thread_mutex_t *mutex;
> >   +#else
> >   +    void               *mutex;
> >   +#endif
> >        apr_pool_t         *owner;
> >        node_t             *free[MAX_INDEX];
> >    };
> 
> Do we even need to define mutex when threads aren't present?  -- justin

if what you really mean to ask is "why do we still have the mutex field?"

answer: to minimize changes, along the lines of the LOCK()/UNLOCK()
macros somebody created.

I don't care either way.  It looked to me like somebody had gone to
the trouble to avoid #if APR_HAS_THREADS all over the place and I
tried to continue with the same goal in mind.

-- 
Jeff Trawick | trawick@attglobal.net | PGP public key at web site:
       http://www.geocities.com/SiliconValley/Park/9289/
             Born in Roswell... married an alien...

Mime
View raw message