[openssl-commits] [openssl] master update

Rich Salz rsalz at openssl.org
Wed Feb 15 13:40:59 UTC 2017


The branch master has been updated
       via  ed874fac6399d5064d6eb8fe2022b918aeaf75af (commit)
      from  bb90d02a71c60bc16389fba4ff06965714b1826f (commit)


- Log -----------------------------------------------------------------
commit ed874fac6399d5064d6eb8fe2022b918aeaf75af
Author: Bernd Edlinger <bernd.edlinger at hotmail.de>
Date:   Wed Feb 15 11:36:17 2017 +0100

    Rework error handling of custom_ext_meth_add towards strong exception safety.
    
    Reviewed-by: Matt Caswell <matt at openssl.org>
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/2636)

-----------------------------------------------------------------------

Summary of changes:
 ssl/t1_ext.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/ssl/t1_ext.c b/ssl/t1_ext.c
index 1821647..b19e752 100644
--- a/ssl/t1_ext.c
+++ b/ssl/t1_ext.c
@@ -179,12 +179,8 @@ static int custom_ext_meth_add(custom_ext_methods *exts,
     tmp = OPENSSL_realloc(exts->meths,
                           (exts->meths_count + 1) * sizeof(custom_ext_method));
 
-    if (tmp == NULL) {
-        OPENSSL_free(exts->meths);
-        exts->meths = NULL;
-        exts->meths_count = 0;
+    if (tmp == NULL)
         return 0;
-    }
 
     exts->meths = tmp;
     meth = exts->meths + exts->meths_count;


More information about the openssl-commits mailing list