From: Joe Orton Date: Sat, 5 Jun 2010 20:35:51 +0000 (+0000) Subject: * modules/echo/mod_echo.c (process_echo_connection): Use _cleanup X-Git-Tag: 2.3.6~53 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f26b981093988de05cb2b2a468c3a72f519c45d0;p=apache * modules/echo/mod_echo.c (process_echo_connection): Use _cleanup rather than _destroy to clear a brigade which is to be re-used. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@951761 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/echo/mod_echo.c b/modules/echo/mod_echo.c index 63e329260b..bc0be70f8c 100644 --- a/modules/echo/mod_echo.c +++ b/modules/echo/mod_echo.c @@ -150,7 +150,7 @@ static int process_echo_connection(conn_rec *c) /* Get a single line of input from the client */ if (((rv = ap_get_brigade(c->input_filters, bb, AP_MODE_GETLINE, APR_BLOCK_READ, 0)) != APR_SUCCESS)) { - apr_brigade_destroy(bb); + apr_brigade_cleanup(bb); if (!APR_STATUS_IS_EOF(rv) && ! APR_STATUS_IS_TIMEUP(rv)) ap_log_error(APLOG_MARK, APLOG_INFO, rv, c->base_server, "ProtocolEcho: Failure reading from %s", @@ -160,7 +160,7 @@ static int process_echo_connection(conn_rec *c) /* Something horribly wrong happened. Someone didn't block! */ if (APR_BRIGADE_EMPTY(bb)) { - apr_brigade_destroy(bb); + apr_brigade_cleanup(bb); ap_log_error(APLOG_MARK, APLOG_INFO, rv, c->base_server, "ProtocolEcho: Error - read empty brigade from %s!", c->remote_ip);