mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-10 07:21:58 +00:00
Cmd_Exec_f: simplified condition for Hunk_FreeToLowMark.
This commit is contained in:
parent
11dd10bd91
commit
8b146122bb
1 changed files with 5 additions and 7 deletions
10
Quake/cmd.c
10
Quake/cmd.c
|
@ -271,9 +271,7 @@ void Cmd_Exec_f (void)
|
|||
|
||||
mark = Hunk_LowMark ();
|
||||
f = (char *)COM_LoadHunkFile (Cmd_Argv(1), NULL);
|
||||
if (!f && !strcmp(Cmd_Argv(1), "default.cfg"))
|
||||
{
|
||||
mark = -1;
|
||||
if (!f && !strcmp(Cmd_Argv(1), "default.cfg")) {
|
||||
f = default_cfg; /* see above.. */
|
||||
}
|
||||
if (!f)
|
||||
|
@ -281,12 +279,12 @@ void Cmd_Exec_f (void)
|
|||
Con_Printf ("couldn't exec %s\n",Cmd_Argv(1));
|
||||
return;
|
||||
}
|
||||
|
||||
Con_Printf ("execing %s\n",Cmd_Argv(1));
|
||||
Cbuf_InsertText (f);
|
||||
|
||||
if (mark < 0) return;
|
||||
Cbuf_InsertText (f);
|
||||
if (f != default_cfg) {
|
||||
Hunk_FreeToLowMark (mark);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue