mirror of
https://git.code.sf.net/p/quake/quakeforge-old
synced 2025-02-15 08:21:41 +00:00
Fixed a segfault when running "./uquake -rogue". Forgot that com_cmdline will
temporarily have an extra char.
This commit is contained in:
parent
0f15bbd803
commit
3e6df0a25e
1 changed files with 1 additions and 1 deletions
|
@ -100,7 +100,7 @@ void COM_InitArgv (int argc, char **argv)
|
|||
len += strlen (argv[com_argc]) + 1;
|
||||
}
|
||||
|
||||
com_cmdline = (char*)malloc (len); // len is strlen(com_cmdline)+1 already
|
||||
com_cmdline = (char*)malloc (len+1); // need strlen(com_cmdline)+2
|
||||
com_cmdline[0] = 0;
|
||||
for (i=0; i < argc; i++)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue