When calling do_game_pause do not allocate msg in Game mod GM_MULTI as it's not used nor freed
This commit is contained in:
parent
f4ec76d74d
commit
970fd72eae
|
@ -3,6 +3,7 @@ D1X-Rebirth Changelog
|
|||
20101204
|
||||
--------
|
||||
main/bmread.c, main/piggy.c: When setting a bogus sound in gamedata_read_tbl, don't let piggy_close free it. Fixes freeing of non-malloc'd pointer for PC shareware data
|
||||
main/gamecntl.c: When calling do_game_pause do not allocate msg in Game mod GM_MULTI as it's not used nor freed
|
||||
|
||||
20101203
|
||||
--------
|
||||
|
|
|
@ -280,10 +280,6 @@ int do_game_pause()
|
|||
char *msg;
|
||||
char total_time[9],level_time[9];
|
||||
|
||||
MALLOC(msg, char, 1024);
|
||||
if (!msg)
|
||||
return 0;
|
||||
|
||||
#ifdef NETWORK
|
||||
if (Game_mode & GM_MULTI)
|
||||
{
|
||||
|
@ -292,6 +288,10 @@ int do_game_pause()
|
|||
}
|
||||
#endif
|
||||
|
||||
MALLOC(msg, char, 1024);
|
||||
if (!msg)
|
||||
return 0;
|
||||
|
||||
songs_pause();
|
||||
|
||||
format_time(total_time, f2i(Players[Player_num].time_total) + Players[Player_num].hours_total*3600);
|
||||
|
|
Loading…
Reference in a new issue