[RCD] Threads - first commit

Chris January chris at atomice.net
Tue Nov 17 13:48:12 CET 2009


> Was 20MB, with x86_64 you have more than 32 MB. Maybe this should be 
> requested as PHP bug to PHP's bugtracker? In the mean time you can try 
> replace line:
> 
> return preg_split('/\s+/', $data, -1, PREG_SPLIT_NO_EMPTY);
> 
> with:
> 
> return array_values(array_filter(explode(' ', $data)));
> 
> or with:
> 
> $res = array();
> $tok = strtok($data, ' ');
> while ($tok !== false) {
>      $res[] = $tok;
>      $tok = strtok(' ');
> }
> return $res;

I tried both methods, but PHP runs out of memory in both cases.

Chris

_______________________________________________
List info: http://lists.roundcube.net/dev/



More information about the Dev mailing list