apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bo...@apache.org
Subject svn commit: r662602 - /apr/apr/branches/1.3.x/include/apr_ring.h
Date Tue, 03 Jun 2008 00:07:01 GMT
Author: bojan
Date: Mon Jun  2 17:07:00 2008
New Revision: 662602

URL: http://svn.apache.org/viewvc?rev=662602&view=rev
Log:
Backport r662299 from the trunk.
Silence GCC strict aliasing warning.

Modified:
    apr/apr/branches/1.3.x/include/apr_ring.h

Modified: apr/apr/branches/1.3.x/include/apr_ring.h
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.3.x/include/apr_ring.h?rev=662602&r1=662601&r2=662602&view=diff
==============================================================================
--- apr/apr/branches/1.3.x/include/apr_ring.h (original)
+++ apr/apr/branches/1.3.x/include/apr_ring.h Mon Jun  2 17:07:00 2008
@@ -157,7 +157,7 @@
  * @param link The name of the APR_RING_ENTRY in the element struct
  */
 #define APR_RING_SENTINEL(hp, elem, link)				\
-    (struct elem *)((char *)(hp) - APR_OFFSETOF(struct elem, link))
+    (struct elem *)((char *)(&(hp)->next) - APR_OFFSETOF(struct elem, link))
 
 /**
  * The first element of the ring



Mime
View raw message