mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 18:57:27 +02:00
add macro guard on test case
This commit is contained in:
@ -195,6 +195,7 @@ static CryptoCb* wc_CryptoCb_FindDevice(int devId, int algoType)
|
|||||||
localDevId = CryptoCb_FindCb(devId, algoType);
|
localDevId = CryptoCb_FindCb(devId, algoType);
|
||||||
}
|
}
|
||||||
#endif /* WOLF_CRYPTO_CB_FIND */
|
#endif /* WOLF_CRYPTO_CB_FIND */
|
||||||
|
(void)algoType;
|
||||||
return wc_CryptoCb_GetDevice(localDevId);
|
return wc_CryptoCb_GetDevice(localDevId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45192,6 +45192,7 @@ static int myCryptoDevCb(int devIdArg, wc_CryptoInfo* info, void* ctx)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef WOLF_CRYPTO_CB_FIND
|
||||||
static int myCryptoCbFind(int currentId, int algoType)
|
static int myCryptoCbFind(int currentId, int algoType)
|
||||||
{
|
{
|
||||||
/* can have algo specific overrides here
|
/* can have algo specific overrides here
|
||||||
@ -45214,6 +45215,7 @@ static int myCryptoCbFind(int currentId, int algoType)
|
|||||||
}
|
}
|
||||||
return currentId;
|
return currentId;
|
||||||
}
|
}
|
||||||
|
#endif /* WOLF_CRYPTO_CB_FIND */
|
||||||
|
|
||||||
|
|
||||||
WOLFSSL_TEST_SUBROUTINE int cryptocb_test(void)
|
WOLFSSL_TEST_SUBROUTINE int cryptocb_test(void)
|
||||||
@ -45228,7 +45230,9 @@ WOLFSSL_TEST_SUBROUTINE int cryptocb_test(void)
|
|||||||
/* set devId to something other than INVALID_DEVID */
|
/* set devId to something other than INVALID_DEVID */
|
||||||
devId = 1;
|
devId = 1;
|
||||||
ret = wc_CryptoCb_RegisterDevice(devId, myCryptoDevCb, &myCtx);
|
ret = wc_CryptoCb_RegisterDevice(devId, myCryptoDevCb, &myCtx);
|
||||||
|
#ifdef WOLF_CRYPTO_CB_FIND
|
||||||
wc_CryptoCb_SetDeviceFindCb(myCryptoCbFind);
|
wc_CryptoCb_SetDeviceFindCb(myCryptoCbFind);
|
||||||
|
#endif /* WOLF_CRYPTO_CB_FIND */
|
||||||
#ifndef WC_NO_RNG
|
#ifndef WC_NO_RNG
|
||||||
if (ret == 0)
|
if (ret == 0)
|
||||||
ret = random_test();
|
ret = random_test();
|
||||||
|
Reference in New Issue
Block a user