From b548a1f11c06ccdfa4f52a539912d22d77ee309e Mon Sep 17 00:00:00 2001 From: Rich Salz Date: Fri, 1 May 2015 10:02:07 -0400 Subject: free null cleanup finale Don't check for NULL before calling OPENSSL_free Reviewed-by: Richard Levitte --- crypto/ui/ui_lib.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'crypto/ui') diff --git a/crypto/ui/ui_lib.c b/crypto/ui/ui_lib.c index d2732f5..26afbd2 100644 --- a/crypto/ui/ui_lib.c +++ b/crypto/ui/ui_lib.c @@ -335,14 +335,10 @@ int UI_dup_input_boolean(UI *ui, const char *prompt, const char *action_desc, ok_chars_copy, cancel_chars_copy, 1, UIT_BOOLEAN, flags, result_buf); err: - if (prompt_copy) - OPENSSL_free(prompt_copy); - if (action_desc_copy) - OPENSSL_free(action_desc_copy); - if (ok_chars_copy) - OPENSSL_free(ok_chars_copy); - if (cancel_chars_copy) - OPENSSL_free(cancel_chars_copy); + OPENSSL_free(prompt_copy); + OPENSSL_free(action_desc_copy); + OPENSSL_free(ok_chars_copy); + OPENSSL_free(cancel_chars_copy); return -1; } -- cgit v1.1