console.c (Con_TabComplete): don't change the length counter in arg completion.

issue seems to have been added in v0.90.1.

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1560 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Ozkan Sezer 2018-02-16 05:57:54 +00:00
parent 45ec3d87f0
commit e62db0b9fb

View file

@ -924,7 +924,7 @@ void Con_TabComplete (void)
const char *match;
static char *c;
tab_t *t;
int mark, i;
int mark, i, j;
// if editline is empty, return
if (key_lines[edit_line][1] == 0)
@ -945,11 +945,11 @@ void Con_TabComplete (void)
// Map autocomplete function -- S.A
// Since we don't have argument completion, this hack will do for now...
for (i=0; i<num_arg_completion_types; i++)
for (j=0; j<num_arg_completion_types; j++)
{
// arg_completion contains a command we can complete the arguments
// for (like "map ") and a list of all the maps.
arg_completion_type_t arg_completion = arg_completion_types[i];
arg_completion_type_t arg_completion = arg_completion_types[j];
const char *command_name = arg_completion.command;
if (!strncmp (key_lines[edit_line] + 1, command_name, strlen(command_name)))