Change 34507 by [EMAIL PROTECTED] on 2008/10/18 18:11:57

        Fix memory leak in // caused by single-char character class
        optimization. This was most probably introduced with #28262.
        This change fixes perl #59516.

Affected files ...

... //depot/perl/regcomp.c#660 edit

Differences ...

==== //depot/perl/regcomp.c#660 (text) ====
Index: perl/regcomp.c
--- perl/regcomp.c#659~34464~   2008-10-05 14:51:54.000000000 -0700
+++ perl/regcomp.c      2008-10-18 11:11:57.000000000 -0700
@@ -8350,6 +8350,9 @@
         *STRING(ret)= (char)value;
         STR_LEN(ret)= 1;
         RExC_emit += STR_SZ(1);
+       if (listsv) {
+           SvREFCNT_dec(listsv);
+       }
         return ret;
     }
     /* optimize case-insensitive simple patterns (e.g. /[a-z]/i) */
End of Patch.

Reply via email to