]> granicus.if.org Git - apache/commitdiff
Fix memory leak in core_output_filter.
authorJustin Erenkrantz <jerenkrantz@apache.org>
Tue, 10 Sep 2002 19:41:43 +0000 (19:41 +0000)
committerJustin Erenkrantz <jerenkrantz@apache.org>
Tue, 10 Sep 2002 19:41:43 +0000 (19:41 +0000)
This would result in at least two EOS buckets being leaked per connection.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96752 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
server/core.c

diff --git a/CHANGES b/CHANGES
index 12cf300e2554fc180c9f03b090ff2cfbe200e5a3..be428d831ea49ca013dc0f39b62f3419753e54ef 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,7 @@
 Changes with Apache 2.0.41
 
+  *) Fix memory leak in core_output_filter.  [Justin Erenkrantz]
+
   *) Add ability to htpasswd (via -5) to produce non-obfuscated MD5 hashes.
      [Justin Erenkrantz]
 
index 6848fd56cdefa577094cae6c57dcea5adbf9c0c0..234de4af93788eb211dcfea1a7215e72e1b6cca9 100644 (file)
@@ -3798,7 +3798,7 @@ static apr_status_t core_output_filter(ap_filter_t *f, apr_bucket_brigade *b)
             if (APR_BUCKET_IS_EOS(last_e)) {
                 apr_bucket *bucket;
                 int file_bucket_saved = 0;
-                APR_BUCKET_REMOVE(last_e);
+                apr_bucket_delete(last_e);
                 for (bucket = APR_BRIGADE_FIRST(b);
                      bucket != APR_BRIGADE_SENTINEL(b);
                      bucket = APR_BUCKET_NEXT(bucket)) {