]> granicus.if.org Git - vim/commitdiff
updated for version 7.2-113 v7.2.113
authorBram Moolenaar <Bram@vim.org>
Sat, 21 Feb 2009 21:04:20 +0000 (21:04 +0000)
committerBram Moolenaar <Bram@vim.org>
Sat, 21 Feb 2009 21:04:20 +0000 (21:04 +0000)
src/regexp.c
src/version.c

index ac60c695aa43ba19aec5c34f5832912859a05c00..00df12d54143170b388d0cc7723a554708f4a336 100644 (file)
@@ -4532,7 +4532,7 @@ regmatch(scan)
                cleanup_subexpr();
                if (!REG_MULTI)         /* Single-line regexp */
                {
-                   if (reg_endp[no] == NULL)
+                   if (reg_startp[no] == NULL || reg_endp[no] == NULL)
                    {
                        /* Backref was not set: Match an empty string. */
                        len = 0;
@@ -4548,7 +4548,7 @@ regmatch(scan)
                }
                else                            /* Multi-line regexp */
                {
-                   if (reg_endpos[no].lnum < 0)
+                   if (reg_startpos[no].lnum < 0 || reg_endpos[no].lnum < 0)
                    {
                        /* Backref was not set: Match an empty string. */
                        len = 0;
@@ -7279,13 +7279,11 @@ reg_submatch(no)
     }
     else
     {
-       if (submatch_match->endp[no] == NULL)
+       s = submatch_match->startp[no];
+       if (s == NULL || submatch_match->endp[no] == NULL)
            retval = NULL;
        else
-       {
-           s = submatch_match->startp[no];
            retval = vim_strnsave(s, (int)(submatch_match->endp[no] - s));
-       }
     }
 
     return retval;
index 9b8ac51f22c7fc6aec315c45309ceb8c5c8c1ece..89ecba0ef236e70049f50aa65539d2e74662b5df 100644 (file)
@@ -676,6 +676,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    113,
 /**/
     112,
 /**/