fix jenkins failure

This commit is contained in:
Hideki Miyazaki
2021-08-07 11:13:41 +09:00
parent 67e773db91
commit a066c48f55
2 changed files with 7 additions and 5 deletions

View File

@ -20555,7 +20555,7 @@ const char* GetCipherSegment(const WOLFSSL_CIPHER* cipher, char n[][MAX_SEGMENT_
offset = cipher->offset; offset = cipher->offset;
if (offset >= (unsigned long)GetCipherNamesSize()) if (offset >= (unsigned long)GetCipherNamesSize())
return WOLFSSL_FAILURE; return NULL;
name = cipher_names[offset].name; name = cipher_names[offset].name;

View File

@ -46725,8 +46725,8 @@ static void test_SSL_CIPHER_get_xxx()
const SSL_CIPHER* cipher = NULL; const SSL_CIPHER* cipher = NULL;
STACK_OF(SSL_CIPHER) *supportedCiphers = NULL; STACK_OF(SSL_CIPHER) *supportedCiphers = NULL;
int i, numCiphers = 0; int i, numCiphers = 0;
SSL_CTX* ctx; SSL_CTX* ctx = NULL;
SSL* ssl; SSL* ssl = NULL;
const char* testCertFile; const char* testCertFile;
const char* testKeyFile; const char* testKeyFile;
char buf[256] = {0}; char buf[256] = {0};
@ -46845,8 +46845,10 @@ static void test_SSL_CIPHER_get_xxx()
} }
} }
SSL_CTX_free(ctx); if (ctx)
SSL_free(ssl); SSL_CTX_free(ctx);
if(ssl)
SSL_free(ssl);
printf(resultFmt, passed); printf(resultFmt, passed);
#endif #endif