[openssl-commits] [openssl] master update

Matt Caswell matt at openssl.org
Wed Mar 7 16:21:26 UTC 2018


The branch master has been updated
       via  d8b67b9d0f711622523c36dbdd1ae3ab01d474f6 (commit)
      from  3e3c7c3646878fbbef07865aca007e112cf0fc26 (commit)


- Log -----------------------------------------------------------------
commit d8b67b9d0f711622523c36dbdd1ae3ab01d474f6
Author: Matt Caswell <matt at openssl.org>
Date:   Tue Mar 6 10:41:47 2018 +0000

    Remove OPENSSL_USE_NODELETE guards in shlibloadtest
    
    PR #3399 converted shlibloadtest to the new test framework. It also
    seemed to add some `OPENSSL_USE_NODELETE` guards to the library
    unloading part of the test. This part was added in a commit with this
    description:
    
        Review feedback; use single main, #ifdef ADD_TEST
    
        Suppose OPENSSL_USE_NODELETE (via Nick Reilly)
    
    Strangely though there doesn't seem to be any relevant review feedback
    in that PR that could justify the addition of those guards. The guards
    do not appear in 1.1.0.
    
    Having the guards changes the nature of the test, so that we only test
    library unloading on platforms where OPENSSL_USE_NODELETE is set (Linux
    and Windows). I can't think of any good reason for this and as it doesn't
    seem to be necessary in 1.1.0 so I think we should remove them.
    
    Reviewed-by: Richard Levitte <levitte at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/5530)

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

Summary of changes:
 test/shlibloadtest.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/test/shlibloadtest.c b/test/shlibloadtest.c
index 131d1f6..5f8ec55 100644
--- a/test/shlibloadtest.c
+++ b/test/shlibloadtest.c
@@ -52,12 +52,10 @@ static int shlib_sym(SHLIB lib, const char *symname, SHLIB_SYM *sym)
     return *sym != NULL;
 }
 
-# ifdef OPENSSL_USE_NODELETE
 static int shlib_close(SHLIB lib)
 {
     return dlclose(lib) != 0 ? 0 : 1;
 }
-# endif
 #endif
 
 #ifdef DSO_WIN32
@@ -81,12 +79,10 @@ static int shlib_sym(SHLIB lib, const char *symname, SHLIB_SYM *sym)
     return *sym != NULL;
 }
 
-# ifdef OPENSSL_USE_NODELETE
 static int shlib_close(SHLIB lib)
 {
     return FreeLibrary(lib) == 0 ? 0 : 1;
 }
-# endif
 #endif
 
 
@@ -149,7 +145,6 @@ static int test_lib(void)
     if (!TEST_int_eq(myOpenSSL_version_num(), OPENSSL_VERSION_NUMBER))
         goto end;
 
-#ifdef OPENSSL_USE_NODELETE
     switch (test_type) {
     case JUST_CRYPTO:
         if (!TEST_true(shlib_close(cryptolib)))
@@ -166,7 +161,6 @@ static int test_lib(void)
             goto end;
         break;
     }
-#endif
 
     result = 1;
 end:


More information about the openssl-commits mailing list