From 90a0b8a4586f545254a19dc0e87b5b3f4d3f946f Mon Sep 17 00:00:00 2001 From: Eduard Sabirov Date: Fri, 27 Dec 2024 12:12:59 +0300 Subject: [PATCH] Fix a bug with freeing up the memory of an object for which memory is allocated using openssl Signed-off-by: Eduard Sabirov --- src/encoder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/encoder.c b/src/encoder.c index f5cae6cb..4376b59f 100644 --- a/src/encoder.c +++ b/src/encoder.c @@ -143,7 +143,7 @@ static int p11prov_rsa_encoder_encode_text(void *inctx, OSSL_CORE_BIO *cbio, uri = p11prov_key_to_uri(ctx->provctx, key, selection); if (uri) { BIO_printf(out, "URI %s\n", uri); - free(uri); + OPENSSL_free(uri); } BIO_free(out);