title: preg_replace throws seg fault
body: <p>When I execute the following code; I get a seg fault every time!  Is this a known bug?  How can I make this code work?</p>
  
  <pre><code>&lt;?php
  $doc = file_get_contents("http://prairieprogressive.com/");
  $replace = array(
      "/&lt;script([\s\S])*?&lt;\/ ?script&gt;/",
      "/&lt;style([\s\S])*?&lt;\/ ?style&gt;/",
      "/&lt;!--([\s\S])*?--&gt;/",
      "/\r\n/"
  );
  $doc = preg_replace($replace,"",$doc);
  echo $doc;
  ?&gt;
  </code></pre>
  
  <p>The error (obviously) looks like:</p>
  
  <pre><code>[root@localhost 2.0]# php test.php
  Segmentation fault (core dumped)
  </code></pre>