diff options
Diffstat (limited to 'soh/src/code')
| -rw-r--r-- | soh/src/code/audio_load.c | 2 | ||||
| -rw-r--r-- | soh/src/code/sys_cfb.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/soh/src/code/audio_load.c b/soh/src/code/audio_load.c index 71197c133..6f6b4f4a3 100644 --- a/soh/src/code/audio_load.c +++ b/soh/src/code/audio_load.c @@ -1364,7 +1364,7 @@ void AudioLoad_Init(void* heap, size_t heapSize) { char** fntList = ResourceMgr_ListFiles("audio/fonts*", &fntListSize); char** customFntList = ResourceMgr_ListFiles("custom/fonts/*", &customFntListSize); - gAudioContext.fontLoadStatus = malloc(customFntListSize + fntListSize); + gAudioContext.fontLoadStatus = calloc(customFntListSize + fntListSize, sizeof(u8)); fontMap = calloc(customFntListSize + fntListSize, sizeof(char*)); fontMapSize = customFntListSize + fntListSize; for (int i = 0; i < fntListSize; i++) { diff --git a/soh/src/code/sys_cfb.c b/soh/src/code/sys_cfb.c index 53e9306bc..8bfb3f669 100644 --- a/soh/src/code/sys_cfb.c +++ b/soh/src/code/sys_cfb.c @@ -36,8 +36,8 @@ void SysCfb_Init(s32 n64dd) { osSyncPrintf("システムが使用する最終アドレスは %08x です\n", sSysCfbEnd); // sSysCfbFbPtr[0] = sSysCfbEnd - (screenSize * 4); // sSysCfbFbPtr[1] = sSysCfbEnd - (screenSize * 2); - sSysCfbFbPtr[0] = malloc(screenSize * 4); - sSysCfbFbPtr[1] = malloc(screenSize * 4); + sSysCfbFbPtr[0] = (uintptr_t)calloc(screenSize, 4); + sSysCfbFbPtr[1] = (uintptr_t)calloc(screenSize, 4); // "Frame buffer addresses are %08x and %08x" // osSyncPrintf("フレームバッファのアドレスは %08x と %08x です\n", sSysCfbFbPtr[0], sSysCfbFbPtr[1]); |
