从Zend Server Community Edition 5.5升级到5.6后,当我尝试使用WSO2 Web Services Framework for PHP连接到Web服务时,PHP遇到了malloc错误。
wsf_php_client.log的最后一行输出是
[debug] (...)/wso2/2.1.0/scripts/dynamic_invocation/wsf_wsdl_util.php(1329) [WSF/PHP] importing xsd: (...) from: (...)
PHP 抛出的错误是
php(38384,0xa0ab0540) malloc: *** error for object 0x401bf61: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
每次尝试的内存地址0xa0ab0540似乎都是一致的。
有没有办法找出问题所在?它是在 php 可执行文件中,还是在 apache PHP 模块中,还是在 WSF/PHP 本身中找到问题?
Zend Server CE 5.6 运行 PHP 5.3.9
PHP 5.3.9-ZS5.6.0 (cli) (built: Dec 22 2011 12:28:41)
malloc 错误似乎与 WSF 扩展有关。从源代码重建它后,我让它按预期工作。与以前唯一的区别是我在编译时向 ./configure
命令添加了CC=clang CXX=clang
。
更新:我的结论有点为时过早。如果我在 WSDL 模式下运行 WSF,则会发生 malloc 错误。如果我显式发送 SOAP 信封,则不会收到错误。WSDL 模式在 Zend Server CE 5.5 上运行时工作正常。