- 论坛徽章:
- 0
|
转自:http://hi.baidu.com/delphiss/blog/item/2dd89f50924af33543a75b39.html
这个bug已经有人登记了:http://bugs.php.net/bug.php?id=52943
Description:
------------
I have PHP 5.3.3 and libiconv 1.13 on a Solaris machine.
When I run the following script. it coredumps.
The same script runs fine with PHP 5.2.6 and libiconv 1.11.
$ more test.php
<?php
$str = "économiques";
$str = iconv('UTF-8', 'UTF-8//IGNORE', $str);
print "$str\n";
?>
$php test.php
Segmentation Fault (core dumped)
我观察到的现象就是php-5.2.6, php-5.2.16和php-5.3.3,在solaris9, 10 (sparc)机器上,执行到iconv函数的时候出现Segmentation Fault。
php-5.2.0不存在此问题
解决办法:
下载php-5.2.0源码,确保make成功
新版本(指5.2.0以后)先./configure,,把php- 5.2.0源码目录下 ext/iconv 替换掉新版本相同目录,再执行新版本的make 和 make install。make过程中会提示iconv的warning,不去理会。
在solaris 10 (sparc) php-5.2.16 中成功。 |
|