From 7becd31bfe9ba0cd77ed9dc034563e0ab513a8c9 Mon Sep 17 00:00:00 2001 From: João Silva Date: Sat, 26 Aug 2017 00:26:09 +0100 Subject: Still cleaning things up... --- source/cheats.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/cheats.c') diff --git a/source/cheats.c b/source/cheats.c index 572fd55..0bedfd4 100644 --- a/source/cheats.c +++ b/source/cheats.c @@ -64,7 +64,7 @@ const char* S9xGameGenieToRaw(const char* code, uint32_t* address, uint8_t* byte uint32_t data = 0; int32_t i; - if (strlen(code) != 9 || *(code + 4) != '-' || !S9xAllHex(code, 4) || !S9xAllHex(code + 5, 4)) + if (strlen(code) != 9 || code[4] != '-' || !S9xAllHex(code, 4) || !S9xAllHex(code + 5, 4)) return "Invalid Game Genie(tm) code - should be 'xxxx-xxxx'."; strcpy(new_code, "0x"); -- cgit v1.2.3