[openssl/openssl] cead7e: Fix error handling in pipelining test

Bernd Edlinger noreply at github.com
Mon Jul 24 09:05:16 UTC 2023

  Branch: refs/heads/openssl-3.1
  Home:   https://github.com/openssl/openssl
  Commit: cead7e5adf1eb686f4badfc69511e959230b8638
  Author: Bernd Edlinger <bernd.edlinger at hotmail.de>
  Date:   2023-07-24 (Mon, 24 Jul 2023)

  Changed paths:
    M test/sslapitest.c

  Log Message:
  Fix error handling in pipelining test

When an early error happens in the test_pipelining
function and idx == 5 the error handling would try
to call OPENSSL_free(msg), but msg is at that time
just a string constant in read-only memory, so a
crash would be the result. Fixed that by using
fragsize as an indication when to free msg.

Reviewed-by: Tom Cosgrove <tom.cosgrove at arm.com>
Reviewed-by: Tomas Mraz <tomas at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/21512)

(cherry picked from commit 06a0d40322e96dbba816b35f82226871f635ec5a)

More information about the openssl-commits mailing list