note 49555 added to function.fclose
| From: | jricher at jacquesricher dot com | Date: | Tue, 01 Feb 2005 14:06:31 +0000 |
| Subject: | note 49555 added to function.fclose | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-84324@lists.php.net to get a copy of this message | ||
It is a GOOD_THING to check the return value from fclose(), as some operating systems only flush
file output on close, and can, therefore, return an error from fclose(). You can catch severe
data-eating errors by doing this.
I learned this the hard way.
----
Manual Page -- http://www.php.net/manual/en/function.fclose.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+49555
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+49555&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+49555&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+49555&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+49555&report=yes&reason=useless
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+49555&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+49555&report=yes
Search -- http://master.php.net/manage/user-notes.php