diff options
Diffstat (limited to 'input/input.c')
-rw-r--r-- | input/input.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/input/input.c b/input/input.c index 402c11b8a3..1427a0cfb0 100644 --- a/input/input.c +++ b/input/input.c @@ -628,7 +628,7 @@ mp_input_parse_cmd(char* str) { } else if(!e) e = ptr+strlen(ptr); l = e-start; ptr2 = start; - for(e = strchr(ptr2,'\\') ; e ; e = strchr(ptr2,'\\')) { + for(e = strchr(ptr2,'\\') ; e && e<start+l ; e = strchr(ptr2,'\\')) { memmove(e,e+1,strlen(e)); ptr2 = e + 1; l--; |