#37004 [NEW]: socket_read with PHP_NORMAL_READ doesnt stop on \n if data is recieved too fast

From: Date: Fri, 07 Apr 2006 02:55:44 +0000
Subject: #37004 [NEW]: socket_read with PHP_NORMAL_READ doesnt stop on \n if data is recieved too fast
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-95404@lists.php.net to get a copy of this message
From: phpdotnet at ericmarques dot com Operating system: FreeBSD 5.4-RELEASE PHP version: 5.1.2 PHP Bug Type: Sockets related Bug description: socket_read with PHP_NORMAL_READ doesnt stop on \n if data is recieved too fast Description: ------------ socket_read with PHP_NORMAL_READ doesnt stop on \n if data is recieved too fast eg. if i open a connection to my socket server with telnet and send "test123 line2 line3 line4" copy it and paste into the telnet window so it sends all 4 lines at once. Reproduce code: --------------- $input = socket_read($socket , 1024, PHP_NORMAL_READ); print "-- Start Input String--\n" print $input; print "--End Input String--\n"; Expected result: ---------------- -- Start Input String-- test123 --End Input String-- Actual result: -------------- -- Start Input String-- test123 line2 line3 line4 --End Input String-- -- Edit bug report at http://bugs.php.net/?id=37004&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=37004&r=trysnapshot44 Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=37004&r=trysnapshot51 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=37004&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=37004&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=37004&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=37004&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=37004&r=needscript Try newer version: http://bugs.php.net/fix.php?id=37004&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=37004&r=support Expected behavior: http://bugs.php.net/fix.php?id=37004&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=37004&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=37004&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=37004&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37004&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=37004&r=dst IIS Stability: http://bugs.php.net/fix.php?id=37004&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=37004&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=37004&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=37004&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=37004&r=mysqlcfg

« previous php.bugs (#95404) next »