diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2001-06-23 12:48:46 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2001-06-23 12:48:46 +0000 |
commit | 2c7bc88d785b40bd12a5080fc3d2ef9445460079 (patch) | |
tree | d43cc854436bb2b0d63ca422e4a27a33c847b125 /apps | |
parent | 54f7ebe789e4dbd9f601452b5bb26432b9754a7b (diff) | |
download | openssl-2c7bc88d785b40bd12a5080fc3d2ef9445460079.tar.gz |
Fix UI leak in apps.
Diffstat (limited to 'apps')
-rw-r--r-- | apps/apps.c | 8 | ||||
-rw-r--r-- | apps/apps.h | 1 | ||||
-rw-r--r-- | apps/openssl.c | 1 |
3 files changed, 10 insertions, 0 deletions
diff --git a/apps/apps.c b/apps/apps.c index 000157772f..9bbf476245 100644 --- a/apps/apps.c +++ b/apps/apps.c @@ -434,6 +434,14 @@ int setup_ui_method() UI_method_set_closer(ui_method, ui_close); return 0; } +void destroy_ui_method() + { + if(ui_method) + { + UI_destroy_method(ui_method); + ui_method = NULL; + } + } int password_callback(char *buf, int bufsiz, int verify, PW_CB_DATA *cb_tmp) { diff --git a/apps/apps.h b/apps/apps.h index 7cf4bf135d..7f3903478f 100644 --- a/apps/apps.h +++ b/apps/apps.h @@ -155,6 +155,7 @@ int password_callback(char *buf, int bufsiz, int verify, PW_CB_DATA *cb_data); int setup_ui_method(); +void destroy_ui_method(); int should_retry(int i); int args_from_file(char *file, int *argc, char **argv[]); diff --git a/apps/openssl.c b/apps/openssl.c index 6a94207848..3b4374a048 100644 --- a/apps/openssl.c +++ b/apps/openssl.c @@ -350,6 +350,7 @@ end: ERR_free_strings(); ENGINE_cleanup(); + destroy_ui_method(); CRYPTO_mem_leaks(bio_err); if (bio_err != NULL) |