|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2008-02-04 18:47 UTC] felipe@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Fri Jan 02 23:00:01 2026 UTC |
Description: ------------ fwrite() writes given data to the file when length paramenter is given as a negative value. This is only applicable to php6. Reproduce code: --------------- <?php $fp = fopen("test.dat", "w"); $data = "data"; var_dump(fwrite($fp, $data, -10) ); fclose($fp); var_dump(readfile("test.dat") ); unlink("test.dat"); ?> Expected result: ---------------- int(0) int(0) Actual result: -------------- int(4) dataint(4)