You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by Justin Erenkrantz <ju...@erenkrantz.com> on 2006/09/01 05:18:28 UTC
Re: svn commit: r438796 - /apr/apr/trunk/atomic/unix/apr_atomic.c
On 8/31/06, William A. Rowe, Jr. <wr...@rowe-clan.net> wrote:
> jerenkrantz@apache.org wrote:
> > --- apr/apr/trunk/atomic/unix/apr_atomic.c (original)
> > +++ apr/apr/trunk/atomic/unix/apr_atomic.c Wed Aug 30 22:10:22 2006
> > @@ -179,7 +179,7 @@
> > #endif /* APR_OVERRIDE_ATOMIC_CAS32 */
> >
> > #if !defined(APR_OVERRIDE_ATOMIC_DEC32)
> > -APR_DECLARE(apr_uint32_t) apr_atomic_dec32(volatile apr_uint32_t *mem)
> > +APR_DECLARE(int) apr_atomic_dec32(volatile apr_uint32_t *mem)
> > {
>
> This appears to be a binary break.
>
> You realize we can play macro magic to enforce the correct type?
>
> In any case, unless I'm imagining things, please revert
No. apr_atomic.h says:
APR_DECLARE(int) apr_atomic_dec32(...)
with this Solaris 10 specific Atomics impl saying:
APR_DECLARE(apr_uint32_t) apr_atomic_dec32(...)
All other implementations of dec32() in apr_atomic.c match the int
return - not the uint32_t return. Therefore, on a 64-bit platform, it
never could compile with the signature mismatch. My commit allows APR
to compile on 64-bit Solaris. -- justin