Mercurial > vim
diff src/fileio.c @ 6963:4bf9538ff25e v7.4.799
patch 7.4.799
Problem: Accessing memory before an allocated block.
Solution: Check for not going before the start of a pattern. (Dominique
Pelle)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Tue, 28 Jul 2015 13:33:45 +0200 |
parents | 4db70c94226b |
children | dc1b678f0e4e |
line wrap: on
line diff
--- a/src/fileio.c +++ b/src/fileio.c @@ -8514,7 +8514,7 @@ do_autocmd_event(event, pat, nested, cmd */ brace_level = 0; for (endpat = pat; *endpat && (*endpat != ',' || brace_level - || endpat[-1] == '\\'); ++endpat) + || (endpat > pat && endpat[-1] == '\\')); ++endpat) { if (*endpat == '{') brace_level++;