From ed92e1ef6832a48697b6132f66b6f3eb9861fb3c Mon Sep 17 00:00:00 2001 From: zeromus Date: Sun, 17 Mar 2019 21:12:47 -0400 Subject: [PATCH] get rid of printf warnings --- desmume/src/GPU.cpp | 2 +- desmume/src/firmware.cpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/desmume/src/GPU.cpp b/desmume/src/GPU.cpp index 7f222ce18..ba89d0c33 100755 --- a/desmume/src/GPU.cpp +++ b/desmume/src/GPU.cpp @@ -6914,7 +6914,7 @@ void GPUEngineBase::REG_DISPx_pack_test() { const GPU_IOREG *r = this->_IORegisterMap; - printf("%08lx %02x\n", (uintptr_t)r, (u32)((uintptr_t)(&r->DISPCNT) - (uintptr_t)r) ); + printf("%p %02x\n", r, (u32)((uintptr_t)(&r->DISPCNT) - (uintptr_t)r) ); printf("\t%02x\n", (u32)((uintptr_t)(&r->DISPSTAT) - (uintptr_t)r) ); printf("\t%02x\n", (u32)((uintptr_t)(&r->VCOUNT) - (uintptr_t)r) ); printf("\t%02x\n", (u32)((uintptr_t)(&r->BGnCNT[GPULayerID_BG0]) - (uintptr_t)r) ); diff --git a/desmume/src/firmware.cpp b/desmume/src/firmware.cpp index ee0c1cf83..0866bb128 100644 --- a/desmume/src/firmware.cpp +++ b/desmume/src/firmware.cpp @@ -1128,7 +1128,7 @@ bool NDS_ReadFirmwareDataFromFile(const char *fileName, NDSFirmwareData *outFirm } else { - printf("Ext. Firmware: Failed to read the firmware data. (%lu out of %lu bytes read.)\n", (unsigned long)readBytes, sizeof(NDSFirmwareData)); + printf("Ext. Firmware: Failed to read the firmware data. (%zu out of %zu bytes read.)\n", readBytes, sizeof(NDSFirmwareData)); result = false; } } @@ -1148,7 +1148,7 @@ bool NDS_ReadFirmwareDataFromFile(const char *fileName, NDSFirmwareData *outFirm } else { - printf("Ext. Firmware: Failed to read the console type. (%lu out of %lu bytes read.)\n", (unsigned long)readBytes, sizeof(FW_HEADER_KEY)); + printf("Ext. Firmware: Failed to read the console type. (%zu out of %zu bytes read.)\n", readBytes, sizeof(FW_HEADER_KEY)); result = false; } } @@ -1160,7 +1160,7 @@ bool NDS_ReadFirmwareDataFromFile(const char *fileName, NDSFirmwareData *outFirm if (readBytes != 6) { - printf("Ext. Firmware: Failed to read the MAC address. (%lu out of %lu bytes read.)\n", (unsigned long)readBytes, sizeof(u8) * 6); + printf("Ext. Firmware: Failed to read the MAC address. (%zu out of %zu bytes read.)\n", readBytes, sizeof(u8) * 6); result = false; } }