Bug #10388: File to file I/O problems

From: Date: Wed, 18 Apr 2001 23:25:10 +0000
Subject: Bug #10388: File to file I/O problems
Groups: php.dev 
Request: Send a blank email to php-dev+get-51902@lists.php.net to get a copy of this message
From: rainwave@email.msn.com Operating system: Windows 98 PHP version: 4.0.4 PHP Bug Type: *Directory/Filesystem functions Bug description: File to file I/O problems Whenever I read from file and write directly to another, such as in this line: fwrite($fileout,fread($filein,255)); Any occurances of the byte 0x0A will be replaced by 0x0D0A. If I try to read indirectly, like this: $out = fread($filein,255); fwrite($fileout,$out); The file will always be saved as ASCII, even if I add the "b" flag to fopen. Is this a bug, or am I making a stupid mistake? Your time and effort are greatly appreciated. ~ Joe Ferris ~ P.S. Magic quotes are off -- Edit Bug report at: http://bugs.php.net/?id=10388&edit=1

« previous php.dev (#51902) next »