diff options
author | notaz | 2013-01-03 04:17:43 +0200 |
---|---|---|
committer | notaz | 2013-01-03 04:17:43 +0200 |
commit | cae602d4e6be9a8f5e75b220cbbe14b67d93550a (patch) | |
tree | 2f4d42d7cca19f9bbb6b7497e934694c357e2ca5 /frontend | |
parent | 7ba3e79c025dfd41ba88bcbe7b330a1a7fd68551 (diff) | |
download | pcsx_rearmed-cae602d4e6be9a8f5e75b220cbbe14b67d93550a.tar.gz pcsx_rearmed-cae602d4e6be9a8f5e75b220cbbe14b67d93550a.tar.bz2 pcsx_rearmed-cae602d4e6be9a8f5e75b220cbbe14b67d93550a.zip |
ignore case for cwcheat
headers can have mixed case, which doesn't match common cheat files?
Diffstat (limited to 'frontend')
-rw-r--r-- | frontend/main.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/frontend/main.c b/frontend/main.c index c8841b9..bd48898 100644 --- a/frontend/main.c +++ b/frontend/main.c @@ -311,12 +311,19 @@ do_state_slot: hud_new_msg = 3; } +static char basic_lcase(char c) +{ + if ('A' <= c && c <= 'Z') + return c - 'A' + 'a'; + return c; +} + static int cdidcmp(const char *id1, const char *id2) { while (*id1 != 0 && *id2 != 0) { if (*id1 == '_') { id1++; continue; } if (*id2 == '_') { id2++; continue; } - if (*id1 != *id2) + if (basic_lcase(*id1) != basic_lcase(*id2)) break; id1++; id2++; |