FreeRTOS-Plus/ThirdParty/WolfSSL-FIPS-Ready/wolfcrypt/src/wc_dsp.c
/* callback function for setting the default handle in single threaded
 * use cases */
callback function for setting the default handle in single threaded
use cases
callback function for setting the default handle in single threaded use cases
static int default_handle_cb(remote_handle64 *handle, int finished, void *ctx)
{
    (void)ctx;
    if (finished == WOLFSSL_HANDLE_DONE) {
        if (wc_UnLockMutex(&handle_mutex) != 0) {
            WOLFSSL_MSG("Unlock handle mutex failed");
            return -1;
        }
    }
    else {
        if (wc_LockMutex(&handle_mutex) != 0) {
            WOLFSSL_MSG("Lock handle mutex failed");
            return -1;
        }
        *handle = defaultHandle;
    }
    return 0;
}
static int default_handle_cb ( remote_handle64 * handle , int finished , void * ctx ) { ( void ) ctx ; if ( finished == WOLFSSL_HANDLE_DONE ) { if ( wc_UnLockMutex ( & handle_mutex ) != 0 ) { WOLFSSL_MSG ( " " ) ; return -1 ; } } else { if ( wc_LockMutex ( & handle_mutex ) != 0 ) { WOLFSSL_MSG ( " " ) ; return -1 ; } * handle = defaultHandle ; } return 0 ; }
callback function for setting the default handle in single threaded
 use cases
callback function for setting the default handle in single threaded use cases