]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Merge r1908502 from trunk:
authorJoe Orton <jorton@apache.org>
Fri, 7 Jul 2023 12:04:17 +0000 (12:04 +0000)
committerJoe Orton <jorton@apache.org>
Fri, 7 Jul 2023 12:04:17 +0000 (12:04 +0000)
mod_http2: Fix memory leak in calc_sha256_hash().
Submitted by: ylavic
Reviewed by: icing, jorton, covener

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1910854 13f79535-47bb-0310-9956-ffa450edef68

modules/http2/h2_push.c

index 462c47002aeacc0014e51e62fc8d63ba8d8055f8..dd0928b7190b68d6560c4dde0cbc7eb532867bd2 100644 (file)
@@ -502,6 +502,7 @@ static void calc_sha256_hash(h2_push_diary *diary, apr_uint64_t *phash, h2_push
     sha256_update(md, push->req->authority);
     sha256_update(md, push->req->path);
     EVP_DigestFinal(md, hash, &len);
+    EVP_MD_CTX_destroy(md);
 
     val = 0;
     for (i = 0; i != len; ++i)