commit | 226c53429109f24e31c17016aedfd7fbf7a9aa50 | [log] [tgz] |
---|---|---|
author | Bram Moolenaar <Bram@vim.org> | Fri Feb 17 14:53:15 2017 +0100 |
committer | Bram Moolenaar <Bram@vim.org> | Fri Feb 17 14:53:15 2017 +0100 |
tree | aa3b07baffa6957250161ba206e8b5f796fe3c06 | |
parent | 4e9dbc74df24dc22d0eeda3741c3fb0e0e7373bf [diff] [blame] |
patch 8.0.0333: illegal memory access when 'complete' ends in a backslash Problem: Illegal memory access when 'complete' ends in a backslash. Solution: Check for trailing backslash. (Dominique Pelle, closes #1478)
diff --git a/src/option.c b/src/option.c index 32e97c9..b5f3a9a 100644 --- a/src/option.c +++ b/src/option.c
@@ -7017,7 +7017,7 @@ /* skip optional filename after 'k' and 's' */ while (*s && *s != ',' && *s != ' ') { - if (*s == '\\') + if (*s == '\\' && s[1] != NUL) ++s; ++s; }