Start introducing test_cas NULL-terminated list

This commit is contained in:
Manuel Pégourié-Gonnard 2015-03-27 10:20:26 +01:00
parent 75f901006b
commit 2f165060f0
4 changed files with 41 additions and 5 deletions
programs/ssl

View file

@ -1327,8 +1327,14 @@ int main( int argc, char *argv[] )
else
#endif
#if defined(POLARSSL_CERTS_C)
ret = x509_crt_parse( &cacert, (const unsigned char *) test_ca_list,
test_ca_list_len );
for( i = 0; test_cas[i] != NULL; i++ )
{
ret = x509_crt_parse( &cacert,
(const unsigned char *) test_cas[i],
test_cas_len[i] );
if( ret != 0 )
break;
}
#else
{
ret = 1;