mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-07-04 14:01:17 +12:00
Fix erroneous check on otpMem in iosu_crypto
/root/cemu/src/Cafe/IOSU/legacy/iosu_crypto.cpp:56:6: warning: comparison of array 'otpMem' equal to a null pointer is always false [-Wtautological-pointer-compare] if (otpMem == nullptr) ^~~~~~ ~~~~~~~ /root/cemu/src/Cafe/IOSU/legacy/iosu_crypto.cpp:230:6: warning: comparison of array 'otpMem' equal to a null pointer is always false [-Wtautological-pointer-compare] if (otpMem == nullptr) ^~~~~~ ~~~~~~~
This commit is contained in:
parent
0aae976c75
commit
d436f1cdec
1 changed files with 2 additions and 2 deletions
|
@ -53,7 +53,7 @@ bool iosuCrypto_getDeviceId(uint32* deviceId)
|
|||
{
|
||||
uint32be deviceIdBE;
|
||||
*deviceId = 0;
|
||||
if (otpMem == nullptr)
|
||||
if (!hasOtpMem)
|
||||
return false;
|
||||
iosuCrypto_readOtpData(&deviceIdBE, 0x87, sizeof(uint32));
|
||||
*deviceId = (uint32)deviceIdBE;
|
||||
|
@ -227,7 +227,7 @@ void iosuCrypto_generateDeviceCertificate()
|
|||
{
|
||||
static_assert(sizeof(g_wiiuDeviceCert) == 0x180);
|
||||
memset(&g_wiiuDeviceCert, 0, sizeof(g_wiiuDeviceCert));
|
||||
if (otpMem == nullptr)
|
||||
if (!hasOtpMem)
|
||||
return; // cant generate certificate without OPT
|
||||
|
||||
// set header based on otp security mode
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue