mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
- replace all \0 characters in Dehacked patches with spaces.
This is needed to make some old and broken patches in some WolfenDoom mods load.
This commit is contained in:
parent
2d4299608c
commit
ec58178695
2 changed files with 7 additions and 1 deletions
|
@ -694,7 +694,7 @@ void C_DoCommand (const char *cmd, int keynum)
|
|||
}
|
||||
else
|
||||
{
|
||||
Printf ("Unknown command \"%.*s\"\n", len, beg);
|
||||
Printf ("Unknown command \"%.*s\"\n", (int)len, beg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2455,6 +2455,12 @@ static bool DoDehPatch()
|
|||
Printf (PRINT_BOLD, "\"%s\" is an old and unsupported DeHackEd patch\n", PatchFile);
|
||||
return false;
|
||||
}
|
||||
// fix for broken WolfenDoom patches which contain \0 characters in some places.
|
||||
for (int i = 0; i < PatchSize; i++)
|
||||
{
|
||||
if (PatchFile[i] == 0) PatchFile[i] = ' ';
|
||||
}
|
||||
|
||||
PatchPt = strchr (PatchFile, '\n');
|
||||
while ((cont = GetLine()) == 1)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue