Bug #76086 [Opn->Fbk]: Unable to write to php://stderr

From: Date: Tue, 13 Mar 2018 09:16:38 +0000
Subject: Bug #76086 [Opn->Fbk]: Unable to write to php://stderr
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-214325@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=76086&edit=1

 ID:                 76086
 Updated by:         ab@php.net
 Reported by:        chris at modd dot com dot au
 Summary:            Unable to write to php://stderr
-Status:             Open
+Status:             Feedback
 Type:               Bug
 Package:            Streams related
 Operating System:   Windows
 PHP Version:        7.2.3
 Block user comment: N
 Private report:     N

 New Comment:

Thanks for the report. I see this when running your snippet

$ php-cgi.exe bug76086.php 1>nul
Error Occurred

How exactly teh issue can be reproduced?

Thanks.


Previous Comments:
------------------------------------------------------------------------
[2018-03-13 05:20:14] chris at modd dot com dot au

This problem only seems to be a problem when using php-cgi

------------------------------------------------------------------------
[2018-03-13 05:20:12] chris at modd dot com dot au

This problem only seems to be a problem when using php-cgi

------------------------------------------------------------------------
[2018-03-13 05:11:48] chris at modd dot com dot au

Description:
------------
Can no longer output to STDERR using file_put_contents. Used to work fine in PHP 5.x.
Also Affects 7.1.x

Test script:
---------------
<?php

$msg = "Error Occurred\n";
file_put_contents("php://stderr", $msg);


Expected result:
----------------
Error Occurred written to console on stderr

Actual result:
--------------
Rather than stderr output error message, I get a warning:
Only 0 of 15 bytes written, possibly out of free diskspace in script.php on line 3


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



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


Thread (12 messages)

« previous php.bugs (#214325) next »