From:             eliteforce at elitemail dot org
Operating system: WinXP (SP2)
PHP version:      5.2.3
PHP Bug Type:     Streams related
Bug description:  STD IN/OUT/ERR undefined

Description:
------------
When running php.exe from the console without any arguments (so the script
can be entered directly) the constants STDIN, STDOUT, STDERR are
undefined.
When running the same code trough a file (php.exe <script>) or with the
php.exe -r arg the constants are defined.

Reproduce code:
---------------
<?php
var_dump(defined('STDIN'));
var_dump(defined('STDOUT'));
var_dump(defined('STDERR'));
?>
^Z


Expected result:
----------------
bool(true)
bool(true)
bool(true)

Actual result:
--------------
bool(false)
bool(false)
bool(false)

-- 
Edit bug report at http://bugs.php.net/?id=42091&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=42091&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=42091&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=42091&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=42091&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=42091&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=42091&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=42091&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=42091&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=42091&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=42091&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=42091&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=42091&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=42091&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=42091&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=42091&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=42091&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=42091&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=42091&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=42091&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=42091&r=mysqlcfg

Reply via email to