PHPUnit 出现分段错误
尝试开始使用 phpunit 但无法正确安装/设置。当我在命令行运行它时,出现分段错误。
Environment:
OSX 10.6.4
PHP 5.3.2 (cli) (built: Aug 7 2010 00:04:41)
About pear.phpunit.de/PHPUnit-3.4.9
我尝试在 php.ini 中禁用 xdebug,但仍然收到错误 - 唯一的区别是它没有出现在崩溃报告中。我有一个 php 的 macports 安装,我删除了它。我还删除了 phpunit 并重新安装了它。详细信息如下:
Process: php [13366]
Path: /usr/bin/php
Identifier: php
Version: ??? (???)
Code Type: X86-64 (Native)
Parent Process: bash [12089]
Date/Time: 2010-10-04 09:40:08.035 -0400
OS Version: Mac OS X 10.6.4 (10F569)
Report Version: 6
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: 0x000000000000000d, 0x0000000000000000
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Thread 0 Crashed: Dispatch queue: com.apple.main-thread
0 inclued.so 0x0000000100bf3e44 inclued_op_ZEND_ADD_INTERFACE + 308
1 php 0x000000010033c4bd ZEND_USER_OPCODE_SPEC_HANDLER + 29
2 php 0x000000010033984d execute + 585
3 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
4 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
5 php 0x000000010033984d execute + 585
6 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
7 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
8 php 0x000000010033984d execute + 585
9 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
10 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
11 php 0x000000010033984d execute + 585
12 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
13 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
14 php 0x000000010033984d execute + 585
15 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
16 php 0x0000000100318558 zend_execute_scripts + 376
17 php 0x00000001002caec5 php_execute_script + 732
18 php 0x0000000100394b9c main + 3646
19 php 0x0000000100001164 start + 52
非常感谢任何帮助!
谢谢
-道格
Trying to get started using phpunit and can't get it installed/setup properly. When I run it command line I get a segmentation fault.
Environment:
OSX 10.6.4
PHP 5.3.2 (cli) (built: Aug 7 2010 00:04:41)
About pear.phpunit.de/PHPUnit-3.4.9
I tried disabling xdebug in php.ini and still got the error - the only difference was it wasn't appearing in the crash report. I had a macports install of php, I removed that. I also removed phpunit and reinstalled it. Here are the details:
Process: php [13366]
Path: /usr/bin/php
Identifier: php
Version: ??? (???)
Code Type: X86-64 (Native)
Parent Process: bash [12089]
Date/Time: 2010-10-04 09:40:08.035 -0400
OS Version: Mac OS X 10.6.4 (10F569)
Report Version: 6
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: 0x000000000000000d, 0x0000000000000000
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Thread 0 Crashed: Dispatch queue: com.apple.main-thread
0 inclued.so 0x0000000100bf3e44 inclued_op_ZEND_ADD_INTERFACE + 308
1 php 0x000000010033c4bd ZEND_USER_OPCODE_SPEC_HANDLER + 29
2 php 0x000000010033984d execute + 585
3 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
4 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
5 php 0x000000010033984d execute + 585
6 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
7 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
8 php 0x000000010033984d execute + 585
9 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
10 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
11 php 0x000000010033984d execute + 585
12 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
13 php 0x0000000100347cd6 ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER + 922
14 php 0x000000010033984d execute + 585
15 xdebug.so 0x0000000100d05f11 xdebug_execute + 3079
16 php 0x0000000100318558 zend_execute_scripts + 376
17 php 0x00000001002caec5 php_execute_script + 732
18 php 0x0000000100394b9c main + 3646
19 php 0x0000000100001164 start + 52
Any help is much appreciated!
Thanks
-Doug
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
清除监视表达式修复了我的分段错误。希望它能帮助某人。
Clearing the watch expressions fixed my segmentation error. Hope it helps someone.
首先,请禁用Xdebug,检查是否是这个原因。如果是,请升级到最新的 Xdebug 版本。
First, please disable Xdebug to check whether it's the reason. If yes, upgrade to the latest Xdebug version.
找到了罪魁祸首...inclued.so 扩展导致了问题。
我恢复到原来的 osx php.ini 并且一切正常,所以我回到了 php.ini 的问题版本,一次删除一件事,包含的扩展是获胜者!
PHP 和 PHPUnit 现在表现得非常好。
Found the culprit... inclued.so extension was causing the problem.
I reverted back to the original osx php.ini and things worked, so I went back to the problem version of php.ini, removed one thing at a time and inclued extension was the winner!
PHP and PHPUnit now behaves quite nicely.