We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9fbe490 commit 792e9c6Copy full SHA for 792e9c6
1 file changed
clink/dll/doskey.c
@@ -117,9 +117,9 @@ int continue_doskey(wchar_t* chars, unsigned max_chars)
117
wchar_t* insert_from;
118
int insert_length = 0;
119
120
- if (c == 0)
+ if (c == 0 && g_state.token_count > 1)
121
{
122
- insert_from = g_state.input + g_state.tokens[0].length;
+ insert_from = g_state.input + g_state.tokens[1].start;
123
insert_length = min(wcslen(insert_from), max_chars);
124
}
125
else if (c < g_state.token_count)
0 commit comments