subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1665259 - /subversion/trunk/subversion/libsvn_ra_serf/util.c
Date Mon, 09 Mar 2015 15:40:19 GMT
Author: rhuijben
Date: Mon Mar  9 15:40:19 2015
New Revision: 1665259

URL: http://svn.apache.org/r1665259
Log:
In ra-serf's error handling: Following up on r1557686, make sure that after we
decide to discard the body, we don't assume that the handler is no longer
scheduled.

A test triggering this issue will be added in a followup patch.

* subversion/libsvn_ra_serf/util.c
  (handle_response_cb): Keep the handler marked as scheduled, to allow processing
    the remaining data (by ignoring) later *or* by resetting the connection if
    the handler's pool is destroyed.

Modified:
    subversion/trunk/subversion/libsvn_ra_serf/util.c

Modified: subversion/trunk/subversion/libsvn_ra_serf/util.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_serf/util.c?rev=1665259&r1=1665258&r2=1665259&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra_serf/util.c (original)
+++ subversion/trunk/subversion/libsvn_ra_serf/util.c Mon Mar  9 15:40:19 2015
@@ -1453,7 +1453,13 @@ handle_response_cb(serf_request_t *reque
     {
       handler->discard_body = TRUE; /* Discard further data */
       handler->done = TRUE; /* Mark as done */
-      handler->scheduled = FALSE;
+      /* handler->scheduled is still TRUE, as we still expect data.
+         If we would return an error outer-status the connection
+         would have to be restarted. With scheduled still TRUE
+         destroying the handler's pool will still reset the
+         connection, avoiding the posibility of returning
+         an error for this handler when a new request is
+         scheduled. */
       outer_status = APR_EAGAIN; /* Exit context loop */
     }
 



Mime
View raw message