[xdebug-dev] svn: /xdebug/ branches/xdebug_2_1/tests/bug00654.phpt branches/xdebug_2_1/xdebug.c trunk/tests/bug00654.phpt trunk/xdebug.c

From: Derick Rethans <derick[@]derickrethans.nl>
Date: Fri, 14 Jan 2011 22:55:22 +0000

derick Fri, 14 Jan 2011 22:55:22 +0000

Revision: http://svn.xdebug.org/cgi-bin/viewvc.cgi?view=rev&revision=3391&root=xdebug

Log:
- Fixed bug #654: Xdebug hides error message in CLI.

Changed paths:
    A xdebug/branches/xdebug_2_1/tests/bug00654.phpt
    U xdebug/branches/xdebug_2_1/xdebug.c
    A xdebug/trunk/tests/bug00654.phpt
    U xdebug/trunk/xdebug.c

Added: xdebug/branches/xdebug_2_1/tests/bug00654.phpt
===================================================================
--- xdebug/branches/xdebug_2_1/tests/bug00654.phpt (rev 0)
+++ xdebug/branches/xdebug_2_1/tests/bug00654.phpt 2011-01-14 22:55:22 UTC (rev 3391)
@@ -0,0 +1,25 @@
+--TEST--
+Test for bug #654: Xdebug hides error message in CLI
+--INI--
+error_reporting=-1
+xdebug.default_enable=1
+--FILE--
+<?php
+echo "FOO\n";
+session_start();
+?>
+--EXPECTF--
+FOO
+
+Warning: session_start(): Cannot send session cookie - headers already sent by (output started at %sbug00654.php:2) in %sbug00654.php on line 3
+
+Call Stack:
+%w%f %w%d 1. {main}() %sbug00654.php:0
+%w%f %w%d 2. session_start() %sbug00654.php:3
+
+
+Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at %sbug00654.php:2) in %sbug00654.php on line 3
+
+Call Stack:
+%w%f %w%d 1. {main}() %sbug00654.php:0
+%w%f %w%d 2. session_start() %sbug00654.php:3

Modified: xdebug/branches/xdebug_2_1/xdebug.c
===================================================================
--- xdebug/branches/xdebug_2_1/xdebug.c 2011-01-14 22:55:21 UTC (rev 3390)
+++ xdebug/branches/xdebug_2_1/xdebug.c 2011-01-14 22:55:22 UTC (rev 3391)
@@ -810,9 +810,6 @@
         orig->internal_function.handler = zif_xdebug_set_time_limit;

         XG(headers) = xdebug_llist_alloc(xdebug_llist_string_dtor);
- if (strcmp(sapi_module.name, "cli") == 0) {
- SG(request_info).no_headers = 1;
- }

         return SUCCESS;
 }

Added: xdebug/trunk/tests/bug00654.phpt
===================================================================
--- xdebug/trunk/tests/bug00654.phpt (rev 0)
+++ xdebug/trunk/tests/bug00654.phpt 2011-01-14 22:55:22 UTC (rev 3391)
@@ -0,0 +1,25 @@
+--TEST--
+Test for bug #654: Xdebug hides error message in CLI
+--INI--
+error_reporting=-1
+xdebug.default_enable=1
+--FILE--
+<?php
+echo "FOO\n";
+session_start();
+?>
+--EXPECTF--
+FOO
+
+Warning: session_start(): Cannot send session cookie - headers already sent by (output started at %sbug00654.php:2) in %sbug00654.php on line 3
+
+Call Stack:
+%w%f %w%d 1. {main}() %sbug00654.php:0
+%w%f %w%d 2. session_start() %sbug00654.php:3
+
+
+Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at %sbug00654.php:2) in %sbug00654.php on line 3
+
+Call Stack:
+%w%f %w%d 1. {main}() %sbug00654.php:0
+%w%f %w%d 2. session_start() %sbug00654.php:3

Modified: xdebug/trunk/xdebug.c
===================================================================
--- xdebug/trunk/xdebug.c 2011-01-14 22:55:21 UTC (rev 3390)
+++ xdebug/trunk/xdebug.c 2011-01-14 22:55:22 UTC (rev 3391)
@@ -845,9 +845,6 @@
         orig->internal_function.handler = zif_xdebug_set_time_limit;

         XG(headers) = xdebug_llist_alloc(xdebug_llist_string_dtor);
- if (strcmp(sapi_module.name, "cli") == 0) {
- SG(request_info).no_headers = 1;
- }

         return SUCCESS;
 }
Received on Fri Jan 14 2011 - 22:55:22 GMT

This archive was generated by hypermail 2.2.0 : Sun Jun 24 2018 - 04:00:03 BST