httpd-apreq-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m..@apache.org
Subject svn commit: r209754 - in /httpd/apreq/trunk: CHANGES include/apreq_util.h
Date Fri, 08 Jul 2005 13:00:32 GMT
Author: max
Date: Fri Jul  8 06:00:28 2005
New Revision: 209754

URL: http://svn.apache.org/viewcvs?rev=209754&view=rev
Log:
apreq_brigade_move() bugfix: pass previous bucket to APR_RING_x()

Modified:
    httpd/apreq/trunk/CHANGES
    httpd/apreq/trunk/include/apreq_util.h

Modified: httpd/apreq/trunk/CHANGES
URL: http://svn.apache.org/viewcvs/httpd/apreq/trunk/CHANGES?rev=209754&r1=209753&r2=209754&view=diff
==============================================================================
--- httpd/apreq/trunk/CHANGES (original)
+++ httpd/apreq/trunk/CHANGES Fri Jul  8 06:00:28 2005
@@ -4,6 +4,11 @@
 
 @section v2_06 Changes with libapreq2-2.06
 
+- C API [max]
+
+  Right-hand limit of apreq_brigade_move() is declared as "excluding",
+  but APR_RING_UNSPLICE() wants an "including" right-hand limit. Fixed
+  this by passing the previous bucket.
 
 - Perl API [joes]
   Drop support for Apache2::Request::new's HOOK_DATA.

Modified: httpd/apreq/trunk/include/apreq_util.h
URL: http://svn.apache.org/viewcvs/httpd/apreq/trunk/include/apreq_util.h?rev=209754&r1=209753&r2=209754&view=diff
==============================================================================
--- httpd/apreq/trunk/include/apreq_util.h (original)
+++ httpd/apreq/trunk/include/apreq_util.h Fri Jul  8 06:00:28 2005
@@ -353,6 +353,12 @@
 
     if (e != APR_BRIGADE_SENTINEL(s)) {
         f = APR_RING_FIRST(&s->list);
+        if (f == e) /* zero buckets to be moved */
+            return;
+
+        /* obtain the last bucket to be moved */
+        e = APR_RING_PREV(e, link);
+
         APR_RING_UNSPLICE(f, e, link);
         APR_RING_SPLICE_HEAD(&d->list, f, e, apr_bucket, link);
     }



Mime
View raw message