MantisBT - Xdebug
View Issue Details
0000314Xdebug(No Category)public2007-10-05 14:452007-10-27 20:25
Debian Lenny
0000314: PHP CLI Error Logging thwarted when XDebug Loaded
PHP Error Logging from CLI scripts is thwarted when the XDebug module is loaded. This does not happen if the XDebug module is not included.
trigger_error('Error', E_USER_ERROR);

When run through the php cli it shows an error on screen (with display_errors=on), but no error is logged to the PHP error log.
If the XDebug module is disabled then PHP CLI behaves as expected.

I'm experiencing this issue on Debian Lenny (testing) with PHP 5.2.3, and XDebug 2.1-dev, but my friend has the same issue on Debian Etch (stable) with XDebug 2.0.0. I've also experienced this issue with XDebug 2.0.0RC4.

I can make a full 'php -i' available on request.
No tags attached.
Issue History
2007-10-05 14:45rgpjonesNew Issue
2007-10-05 14:46rgpjonesNote Added: 0000735
2007-10-10 18:48rgpjonesNote Added: 0000736
2007-10-27 20:25derickStatusnew => closed
2007-10-27 20:25derickNote Added: 0000771
2016-07-31 13:35derickCategoryDebug client (console) => debugclient (debugging tool)
2016-07-31 13:35derickCategorydebugclient (debugging tool) => (No Category)

2007-10-05 14:46   
Sorry, I raised this in "Debug Client". I meant "Usage Problems"
2007-10-10 18:48   
Sorry... this is a dupe of 0000232

If you are experiencing this issue then you need to edit the source code:

file: xdebug.c
function: log_stack
remove the if clause:
if (is_cli) {

Recompile and install:
./configure --enable-xdebug
sudo make install
2007-10-27 20:25   
Fixed in CVS, thanks for your report!