]> git.ipfire.org Git - thirdparty/openssl.git/commit
crypto/ui/ui_lib.c: Add OPENSSL_free to avoid memory leaks
authorJiashengJiang <jiasheng@purdue.edu>
Tue, 1 Apr 2025 01:22:53 +0000 (21:22 -0400)
committerMatt Caswell <matt@openssl.org>
Mon, 14 Apr 2025 14:21:49 +0000 (15:21 +0100)
commitf10de53f45d483e0f234590332ad825aae472c69
tree38110c4ff923ff94fd57ec531113c6c5c9b798a0
parentf6d6965dd138d9b86275a16f1264a913b054c49c
crypto/ui/ui_lib.c: Add OPENSSL_free to avoid memory leaks

Add OPENSSL_free() if general_allocate_boolean() or general_allocate_string fails to avoid memory leaks.

Fixes: a63d5eaab2 ("Add a general user interface API. This is designed to replace things like des_read_password and friends (backward compatibility functions using this new API are provided). The purpose is to remove prompting functions from the DES code section as well as provide for prompting through dialog boxes in a window system and the like.")
Signed-off-by: JiashengJiang <jiasheng@purdue.edu>
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Paul Dale <ppzgs1@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/27218)

(cherry picked from commit 8f06efe234ca875eb09af7f35f1ad3d62be696aa)
crypto/ui/ui_lib.c