From:             jkmail at tpg dot com dot au
Operating system: FreeBSD 4.9
PHP version:      5.0.0RC1
PHP Bug Type:     Variables related
Bug description:  Bad output of variable

Description:
------------
When executing this code from STDIN (via CLI), an extra 'D' character
appears in the output for the first time the function is executed.



It behaves normally when its reading the code from a file. Could this be
the 'D' character from the 'Ctrl-D' combination somehow appearing?



Configure:

'./configure' '--prefix=/usr/local/php5' '--with-apxs2' '--disable-cgi'
'--disable-ipv6' '--with-openssl' '--enable-bcmath' '--with-bzip2'
'--with-curl' '--with-gd' '--enable-gd-native-ttf' '--with-imap'
'--with-mysql=/usr/local/lib/mysql' '--enable-soap' '--with-xmlrpc'
'--with-zlib-dir=/usr'

Reproduce code:
---------------
<?php

function a() {

        $var = 4;

        print $var . "\n";

}



a();

a();

?>

Expected result:
----------------
4

4

Actual result:
--------------
4D

4

-- 
Edit bug report at http://bugs.php.net/?id=27955&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=27955&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=27955&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=27955&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=27955&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=27955&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=27955&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=27955&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=27955&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=27955&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=27955&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=27955&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=27955&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=27955&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=27955&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=27955&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=27955&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=27955&r=float

Reply via email to