Skip to content

Commit b747748

Browse files
Fix strncmp mistake
1 parent 26d1d16 commit b747748

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

source/Main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class BobbleHead {
3838
ThiscallEvent <AddressList<0x602BE7, H_CALL>, PRIORITY_AFTER, ArgPick2N<CPad*, 0, int, 1>, void(CPad*, int)> addToPCCheatString;
3939
#endif
4040
addToPCCheatString += [] (CPad* pad, int) {
41-
if (!strncmp(cheatString, pad->KeyBoardCheatString, sizeof(cheatString) - 1)) {
41+
if (!strncmp(cheatString, pad->KeyBoardCheatString, 11)) {
4242
bobbleHeads = bobbleHeads == false;
4343
CHud::SetHelpMessage(TheText.Get(bobbleHeads ? "CHEATON" : "CHEATOF"), true);
4444
}

0 commit comments

Comments
 (0)