mirror of https://github.com/mgba-emu/mgba.git
GBA Cheats: Remove trailing newline
This commit is contained in:
parent
e436f2a727
commit
26e9e8d63f
|
@ -265,6 +265,7 @@ bool GBACheatParseFile(struct GBACheatDevice* device, struct VFile* vf) {
|
||||||
do {
|
do {
|
||||||
++i;
|
++i;
|
||||||
} while (isspace((int) cheat[i]));
|
} while (isspace((int) cheat[i]));
|
||||||
|
cheat[strlen(cheat) - 1] = '\0'; // Remove trailing newline
|
||||||
newSet = malloc(sizeof(*set));
|
newSet = malloc(sizeof(*set));
|
||||||
GBACheatSetInit(newSet, &cheat[i]);
|
GBACheatSetInit(newSet, &cheat[i]);
|
||||||
newSet->enabled = !nextDisabled;
|
newSet->enabled = !nextDisabled;
|
||||||
|
|
Loading…
Reference in New Issue