mirror of
https://github.com/rvtr/ctr_Repair.git
synced 2025-10-31 13:51:08 -04:00
ファイルリストが空のときにASSERTで停止しないように
git-svn-id: file:///Volumes/Transfer/gigaleak_20231201/2020-05-23%20-%20ctr.7z%20+%20svn_v1.068.zip/ctr/svn/ctr_Repair@542 385bec56-5757-e545-9c3a-d8741f4650f1
This commit is contained in:
parent
4ab71f7b74
commit
8b698a0a93
@ -35,6 +35,7 @@
|
||||
#include <nn/mcu.h>
|
||||
#include <nn/drivers/mcu/CTR/driverMcuRegisterMap.h>
|
||||
#include <nn/ndm.h>
|
||||
#include <nn/crypto/crypto_AesCmac.h>
|
||||
|
||||
#include "FileName.h"
|
||||
#include "Importer.h"
|
||||
@ -1843,6 +1844,17 @@ nn::Result ReadFileList(SdFileSize* sdFiles, common::ImportDataList* fileList)
|
||||
file.Finalize();
|
||||
}
|
||||
|
||||
// 初期化状態の場合は空
|
||||
if(fileSize == nn::crypto::AES_CMAC_MAC_SIZE)
|
||||
{
|
||||
sdFiles->ctrFileSize = 0;
|
||||
sdFiles->totalFileSize = 0;
|
||||
sdFiles->twlFileSize = 0;
|
||||
sdFiles->twlPhotoFileSize = 0;
|
||||
sdFiles->twlSoundFileSize = 0;
|
||||
return nn::ResultSuccess();
|
||||
}
|
||||
|
||||
common::HeapManager heap(fileSize);
|
||||
void* buf = heap.GetAddr();
|
||||
if(buf != NULL)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user