From: Bram Moolenaar Date: Fri, 4 Apr 2014 17:00:48 +0000 (+0200) Subject: updated for version 7.4.245 X-Git-Tag: v7.4.245 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=21e854e5ce08ad419441136b1698d535ff818a72;p=vim updated for version 7.4.245 Problem: Crash for "vim -u NONE -N -c '&&'". Solution: Check for the pattern to be NULL. (Dominique Pelle) --- diff --git a/src/ex_cmds.c b/src/ex_cmds.c index 5321955cf..7ae4917a8 100644 --- a/src/ex_cmds.c +++ b/src/ex_cmds.c @@ -4425,7 +4425,7 @@ do_sub(eap) * TODO: find a generic solution to make line-joining operations more * efficient, avoid allocating a string that grows in size. */ - if (STRCMP(pat, "\\n") == 0 && STRLEN(pat) == 2 + if (pat != NULL && STRCMP(pat, "\\n") == 0 && *sub == NUL && (*cmd == NUL || (cmd[1] == NUL && (*cmd == 'g' || *cmd == 'l' || *cmd == 'p' || *cmd == '#')))) diff --git a/src/version.c b/src/version.c index da98b0ab9..e38acfbd5 100644 --- a/src/version.c +++ b/src/version.c @@ -734,6 +734,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 245, /**/ 244, /**/