Author: chromatic
Date: Tue Mar 27 11:35:54 2007
New Revision: 17792

Modified:
   trunk/t/examples/shootout.t

Log:
Fix overzealous flag removal; avoid hangs for platforms without CGP or JIT
(Andy Dougherty, RT #42135).

Modified: trunk/t/examples/shootout.t
==============================================================================
--- trunk/t/examples/shootout.t (original)
+++ trunk/t/examples/shootout.t Tue Mar 27 11:35:54 2007
@@ -84,11 +84,12 @@
     }
     unless ( $PConfig{cg_flag} =~ /HAVE/ ) {
         $args =~ s/-Cj/-j/;
-        $args =~ s/C//;
+        # Remove any plain -C option.
+        $args =~ s/(^|\s)-C(\s|$)/$1$2/;
+        # Remove any extra Cs still floating around
+        $args =~ s/C//; 
     }
 
-    $args eq '-' and $args = '';
-
     # look for input files
     my $input = "$file$INPUT_EXT";
     if ( -e $input ) {

Reply via email to