mirror of
https://github.com/onyx-and-iris/vmrcli.git
synced 2025-01-18 08:41:08 +00:00
ensure we don't step past the NUL terminator here.
This commit is contained in:
parent
161b1061c4
commit
49604b874b
@ -192,10 +192,10 @@ void interactive(T_VBVMR_INTERFACE *vmr)
|
||||
p++;
|
||||
continue;
|
||||
}
|
||||
i = 0;
|
||||
log_trace("commands still in buffer: %s", p);
|
||||
|
||||
while (!isspace(*p))
|
||||
i = 0;
|
||||
while (*p && !isspace(*p))
|
||||
command[i++] = *p++;
|
||||
command[i] = '\0';
|
||||
p++; /* shift to next char */
|
||||
|
Loading…
Reference in New Issue
Block a user