diff --git a/desmume/src/cheatSystem.cpp b/desmume/src/cheatSystem.cpp index 14531c4cd..a5860f545 100644 --- a/desmume/src/cheatSystem.cpp +++ b/desmume/src/cheatSystem.cpp @@ -1553,7 +1553,8 @@ bool CHEATSEXPORT::search() } //printf("serial: %s, offset %08X\n", fat.serial, fat.addr); - if (memcmp(gameInfo.header.gameCode, &fat.serial[0], 4) == 0) + if (gameInfo.crcForCheatsDb == fat.CRC + && !memcmp(gameInfo.header.gameCode, &fat.serial[0], 4)) { dataSize = fat_tmp.addr?(fat_tmp.addr - fat.addr):0; if (encrypted) diff --git a/desmume/src/frontend/windows/cheatsWin.cpp b/desmume/src/frontend/windows/cheatsWin.cpp index 45f8f07d9..25a8d16bc 100644 --- a/desmume/src/frontend/windows/cheatsWin.cpp +++ b/desmume/src/frontend/windows/cheatsWin.cpp @@ -1564,8 +1564,6 @@ INT_PTR CALLBACK CheatsExportProc(HWND dialog, UINT msg,WPARAM wparam,LPARAM lpa lvi.pszText= tmp[i].description; SendMessage(exportListView, LVM_INSERTITEM, 0, (LPARAM)&lvi); } - if (gameInfo.crc && (gameInfo.crcForCheatsDb != cheatsExport->CRC)) - msgbox->warn("Checksums not matching"); SendMessage(exportListView, WM_SETREDRAW, (WPARAM)TRUE,0); ListView_SetItemState(exportListView,0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED); @@ -1646,7 +1644,7 @@ bool CheatsExportDialog(HWND hwnd) sprintf(buf2, "File \"%s\" is not R4 cheats database.\nWrong file format!", buf); else if (cheatsExport->getErrorCode() == 3) - sprintf(buf2, "Serial \"%s\" not found in database.", gameInfo.ROMserial); + sprintf(buf2, "CRC %8X not found in database.", gameInfo.crcForCheatsDb); else if (cheatsExport->getErrorCode() == 4) sprintf(buf2, "Error export from database");