mirror of https://github.com/wolfSSL/wolfssl.git
Fix for example client/server with `-H exitWithRet` option to make sure all cleanup is performed. Resolves valgrind report due to `TicketCleanup()` not being called.
parent
325402cf5a
commit
3fd47bdff3
|
@ -2115,7 +2115,7 @@ THREAD_RETURN WOLFSSL_THREAD client_test(void* args)
|
||||||
/* if you're getting an error here */
|
/* if you're getting an error here */
|
||||||
|
|
||||||
((func_args*)args)->return_code = err;
|
((func_args*)args)->return_code = err;
|
||||||
return 0;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
showPeer(ssl);
|
showPeer(ssl);
|
||||||
|
@ -2577,6 +2577,8 @@ THREAD_RETURN WOLFSSL_THREAD client_test(void* args)
|
||||||
|
|
||||||
((func_args*)args)->return_code = 0;
|
((func_args*)args)->return_code = 0;
|
||||||
|
|
||||||
|
exit:
|
||||||
|
|
||||||
#ifdef WOLFSSL_ASYNC_CRYPT
|
#ifdef WOLFSSL_ASYNC_CRYPT
|
||||||
wolfAsync_DevClose(&devId);
|
wolfAsync_DevClose(&devId);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1490,7 +1490,7 @@ THREAD_RETURN CYASSL_THREAD server_test(void* args)
|
||||||
err_sys_ex(runWithErrors, "SSL_accept failed");
|
err_sys_ex(runWithErrors, "SSL_accept failed");
|
||||||
|
|
||||||
((func_args*)args)->return_code = err;
|
((func_args*)args)->return_code = err;
|
||||||
return 0;
|
goto exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
showPeer(ssl);
|
showPeer(ssl);
|
||||||
|
@ -1677,6 +1677,7 @@ THREAD_RETURN CYASSL_THREAD server_test(void* args)
|
||||||
|
|
||||||
((func_args*)args)->return_code = 0;
|
((func_args*)args)->return_code = 0;
|
||||||
|
|
||||||
|
exit:
|
||||||
|
|
||||||
#if defined(NO_MAIN_DRIVER) && defined(HAVE_ECC) && defined(FP_ECC) \
|
#if defined(NO_MAIN_DRIVER) && defined(HAVE_ECC) && defined(FP_ECC) \
|
||||||
&& defined(HAVE_THREAD_LS)
|
&& defined(HAVE_THREAD_LS)
|
||||||
|
|
Loading…
Reference in New Issue