mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-10 06:41:41 +00:00
- Fixed: The sidedef loader could allocate insufficient memory if a map
contained unused sidedefs. - Fixed: Color control sequences were written to the log file. Since any entered console command contains such a sequence it was quite noticable. SVN r208 (trunk)
This commit is contained in:
parent
f356e356a0
commit
14765bf64b
3 changed files with 27 additions and 4 deletions
|
@ -1,4 +1,8 @@
|
|||
June 21, 2006 (Changes by Graf Zahl)
|
||||
- Fixed: The sidedef loader could allocate insufficient memory if a map
|
||||
contained unused sidedefs.
|
||||
- Fixed: Color control sequences were written to the log file. Since any
|
||||
entered console command contains such a sequence it was quite noticable.
|
||||
- Fixed: The obituary code didn't use the attacker's name for kills caused
|
||||
by other players.
|
||||
- Fixed: PIT_StompThing never checked for COMPATF_NO_PASSMOBJ.
|
||||
|
|
|
@ -811,7 +811,27 @@ int PrintString (int printlevel, const char *outline)
|
|||
|
||||
if (Logfile)
|
||||
{
|
||||
fputs (outline, Logfile);
|
||||
// Strip out any color escape sequences before writing to the log file
|
||||
char * copy = new char[strlen(outline)+1];
|
||||
const char * srcp = outline;
|
||||
char * dstp = copy;
|
||||
|
||||
while (*srcp != 0)
|
||||
{
|
||||
if (*srcp!=0x1c)
|
||||
{
|
||||
*dstp++=*srcp++;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (srcp[1]!=0) srcp+=2;
|
||||
else break;
|
||||
}
|
||||
}
|
||||
*dstp=0;
|
||||
|
||||
fputs (copy, Logfile);
|
||||
delete [] copy;
|
||||
//#ifdef _DEBUG
|
||||
fflush (Logfile);
|
||||
//#endif
|
||||
|
|
|
@ -2083,15 +2083,14 @@ void P_LoadSideDefs2 (MapData * map)
|
|||
{
|
||||
int i;
|
||||
char name[9];
|
||||
mapsidedef_t * msdf = new mapsidedef_t[numsides+1];
|
||||
|
||||
char * msdf = new char[map->Size(ML_SIDEDEFS)];
|
||||
map->Read(ML_SIDEDEFS, msdf);
|
||||
|
||||
name[8] = 0;
|
||||
|
||||
for (i = 0; i < numsides; i++)
|
||||
{
|
||||
mapsidedef_t *msd = msdf + sidetemp[i].a.map;
|
||||
mapsidedef_t *msd = ((mapsidedef_t*)msdf) + sidetemp[i].a.map;
|
||||
side_t *sd = sides + i;
|
||||
sector_t *sec;
|
||||
|
||||
|
|
Loading…
Reference in a new issue