Bug #50921 [Com]: '200 OK' HTTP status despite PHP error

From: Date: Mon, 28 Apr 2014 14:40:56 +0000
Subject: Bug #50921 [Com]: '200 OK' HTTP status despite PHP error
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-185480@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=50921&edit=1

 ID:                 50921
 Comment by:         ruben at rubensayshi dot com
 Reported by:        phpbug at starurl dot com
 Summary:            '200 OK' HTTP status despite PHP error
 Status:             Not a bug
 Type:               Bug
 Package:            HTTP related
 Operating System:   *
 PHP Version:        5.2.12
 Block user comment: N
 Private report:     N

 New Comment:

still having this issue with "PHP Version: 5.4.27-1+deb.sury.org~precise+1" with xdebug
turned on or off, doesn't seem to make a difference ...

display_errors off does, as already stated by others.


Previous Comments:
------------------------------------------------------------------------
[2013-05-28 21:42:30] kwintersnc at gmail dot com

According to http://bugs.xdebug.org/view.php?id=587 this is
fixed in PHP 5.4, so 
"Not a bug" isn't correct.

------------------------------------------------------------------------
[2013-04-13 19:01:39] matteosistisette at gmail dot com

The status is wrong. And oh my god, since 2010!!

This IS a bug.

Display_errors off means don't DISPLAY errors, it shouldn't have any effect on 
the response code.

Default response for fatal errors should be 500 whether or not display_errors is 
turned on.

------------------------------------------------------------------------
[2010-11-19 11:48:27] dean at deansas dot org

> The reason why display errors needs to be turned of, is because
> displayed errors generate output, and output causes the headers 
> to be send out. I'm afraid we can't do much about this.

Can't PHPs error handling first set a 500 header and then output
error messages as appropriate? 

It doesn't seem to me like this is something that can never ever be fixed

------------------------------------------------------------------------
[2010-08-12 15:40:32] tyra3l at gmail dot com

It's seems that this is a known bug in the xdebug, see:
http://bugs.xdebug.org/view.php?id=587

but couldn't fix it without making some changes in php itself:

"Before I can address this, there need to be some changes in PHP itself. It 
doesn't expose some required information to extensions yet that I will need."

I hope this get fixed soon.

Tyrael

------------------------------------------------------------------------
[2010-08-12 15:35:41] tyra3l at gmail dot com

I can reproduce the problem.
I found out, that if I enable xdebug, then I get header 200, if I disable it, then 
it's 500.
Will report it to Derick.

Tyrael

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=50921


-- 
Edit this bug report at https://bugs.php.net/bug.php?id=50921&edit=1


Thread (33 messages)

« previous php.bugs (#185480) next »