httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bri...@apache.org
Subject svn commit: r353838 - /httpd/httpd/branches/async-read-dev/server/protocol.c
Date Sun, 04 Dec 2005 09:36:09 GMT
Author: brianp
Date: Sun Dec  4 01:36:06 2005
New Revision: 353838

URL: http://svn.apache.org/viewcvs?rev=353838&view=rev
Log:
Free a temporary brigade in read_partial_request()

Modified:
    httpd/httpd/branches/async-read-dev/server/protocol.c

Modified: httpd/httpd/branches/async-read-dev/server/protocol.c
URL: http://svn.apache.org/viewcvs/httpd/httpd/branches/async-read-dev/server/protocol.c?rev=353838&r1=353837&r2=353838&view=diff
==============================================================================
--- httpd/httpd/branches/async-read-dev/server/protocol.c (original)
+++ httpd/httpd/branches/async-read-dev/server/protocol.c Sun Dec  4 01:36:06 2005
@@ -945,6 +945,7 @@
 
 static apr_status_t read_partial_request(request_rec *r) {
     apr_bucket_brigade *tmp_bb;
+    apr_status_t rv = APR_SUCCESS;
 
     /* Read and process lines of the request until we
      * encounter a complete request header, an error, or EAGAIN
@@ -953,7 +954,6 @@
     while (r->status == HTTP_REQUEST_TIME_OUT) {
         char *line = NULL;
         apr_size_t line_length;
-        apr_status_t rv;
         apr_size_t length_limit;
         int first_line = (r->the_request == NULL);
         if (first_line) {
@@ -995,10 +995,11 @@
                     r->status = HTTP_BAD_REQUEST;
                 }
             }
-            return rv;
+            break;
         }
     }
-    return APR_SUCCESS;
+    apr_brigade_destroy(tmp_bb);
+    return rv;
 }
 
 request_rec *ap_read_request(conn_rec *conn)



Mime
View raw message