Change 18041 by [EMAIL PROTECTED] on 2002/10/21 01:14:48

        Subject: Re: [perl #18019] regex overoptimization
        From: [EMAIL PROTECTED]
        Date: Mon, 21 Oct 2002 03:21:54 +0100
        Message-Id: <[EMAIL PROTECTED]>

Affected files ...

.... //depot/perl/regcomp.c#309 edit
.... //depot/perl/t/op/re_tests#79 edit

Differences ...

==== //depot/perl/regcomp.c#309 (text) ====
Index: perl/regcomp.c
--- perl/regcomp.c#308~17656~   Sat Jul 27 23:12:33 2002
+++ perl/regcomp.c      Sun Oct 20 18:14:48 2002
@@ -1306,8 +1306,8 @@
                        } else {
                            /* start offset must point into the last copy */
                            data->last_start_min += minnext * (mincount - 1);
-                           data->last_start_max += is_inf ? 0 : (maxcount - 1)
-                               * (minnext + data->pos_delta);
+                           data->last_start_max += is_inf ? I32_MAX
+                               : (maxcount - 1) * (minnext + data->pos_delta);
                        }
                    }
                    /* It is counted once already... */

==== //depot/perl/t/op/re_tests#79 (text) ====
Index: perl/t/op/re_tests
--- perl/t/op/re_tests#78~17787~        Mon Aug 26 12:22:27 2002
+++ perl/t/op/re_tests  Sun Oct 20 18:14:48 2002
@@ -923,3 +923,4 @@
 2(]*)?$\1      2       y       $&      2
 (??{}) x       y       -       -
 a(b)?? abc     y       <$1>    <>      # undef [perl #16773]
+(\d{1,3}\.){3,}        128.134.142.8   y       <$1>    <142.>  # [perl #18019]
End of Patch.

Reply via email to