1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-28 00:21:48 +03:00

Check return value of ssl_set_xxx() in programs

This commit is contained in:
Manuel Pégourié-Gonnard
2014-07-08 14:05:52 +02:00
parent 14beb08542
commit c5fd391e04
8 changed files with 108 additions and 24 deletions

View File

@ -270,7 +270,11 @@ int main( int argc, char *argv[] )
net_send, &client_fd );
ssl_set_ca_chain( &ssl, srvcert.next, NULL, NULL );
ssl_set_own_cert( &ssl, &srvcert, &pkey );
if( ( ret = ssl_set_own_cert( &ssl, &srvcert, &pkey ) ) != 0 )
{
printf( " failed\n ! ssl_set_own_cert returned %d\n\n", ret );
goto exit;
}
/*
* 5. Handshake