[Remove entries to the current 2.0 section below, when backported]
+ *) Modify ap_get_client_block() to note if it has seen EOS.
+ [Justin Erenkrantz]
+
*) The bucket brigades subsystem now honors the MaxMemFree setting.
[Cliff Woolley, Jean-Jacques Clar]
APACHE 2.1 STATUS: -*-text-*-
-Last modified at [$Date: 2003/08/06 04:02:34 $]
+Last modified at [$Date: 2003/08/31 16:14:38 $]
Release [NOTE that only Alpha/Beta releases occur in 2.1 development]:
* the edge connection filter cannot be removed
http://marc.theaimsgroup.com/?l=apache-httpd-dev&m=105366252619530&w=2
- * bug in ap_get_client_block (wrong handling of EOS)
- http://marc.theaimsgroup.com/?l=apache-httpd-dev&m=105281649228629&w=2
-
CURRENT VOTES:
* Promote mod_cache from experimental to non-experimental
apr_status_t rv;
apr_bucket_brigade *bb;
+ if (r->remaining < 0 || (!r->read_chunked && r->remaining == 0)) {
+ return 0;
+ }
+
bb = apr_brigade_create(r->pool, r->connection->bucket_alloc);
if (bb == NULL) {
r->connection->keepalive = AP_CONN_CLOSE;
* returning data when requested.
*/
AP_DEBUG_ASSERT(!APR_BRIGADE_EMPTY(bb));
-
+
+ /* Check to see if EOS in the brigade.
+ *
+ * If so, we have to leave a nugget for the *next* ap_get_client_block
+ * call to return 0.
+ */
+ if (APR_BUCKET_IS_EOS(APR_BRIGADE_LAST(bb))) {
+ if (r->read_chunked) {
+ r->remaining = -1;
+ }
+ else {
+ r->remaining = 0;
+ }
+ }
+
rv = apr_brigade_flatten(bb, buffer, &bufsiz);
if (rv != APR_SUCCESS) {
apr_brigade_destroy(bb);