From: Bram Moolenaar Date: Tue, 21 Jul 2020 20:25:51 +0000 (+0200) Subject: patch 8.2.1265: crash with EXITFREE when split() fails X-Git-Tag: v8.2.1265 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7d5e744162c1e971e5a863e89787cadc8e56051c;p=vim patch 8.2.1265: crash with EXITFREE when split() fails Problem: Crash with EXITFREE when split() fails. Solution: Restore 'cpoptions'. --- diff --git a/src/evalfunc.c b/src/evalfunc.c index 5de49c5d5..c07b1ab77 100644 --- a/src/evalfunc.c +++ b/src/evalfunc.c @@ -7859,9 +7859,9 @@ f_split(typval_T *argvars, typval_T *rettv) pat = (char_u *)"[\\x01- ]\\+"; if (rettv_list_alloc(rettv) == FAIL) - return; + goto theend; if (typeerr) - return; + goto theend; regmatch.regprog = vim_regcomp(pat, RE_MAGIC + RE_STRING); if (regmatch.regprog != NULL) @@ -7898,6 +7898,7 @@ f_split(typval_T *argvars, typval_T *rettv) vim_regfree(regmatch.regprog); } +theend: p_cpo = save_cpo; } diff --git a/src/version.c b/src/version.c index 9b6f1b41a..d6d74346c 100644 --- a/src/version.c +++ b/src/version.c @@ -754,6 +754,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 1265, /**/ 1264, /**/