fclose(), file_put_contents(), copy() all fail to return false on error
| From: | Tom Boutell | Date: | Fri, 21 Oct 2011 19:40:08 +0000 |
| Subject: | fclose(), file_put_contents(), copy() all fail to return false on error | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-55886@lists.php.net to get a copy of this message | ||
It appears that all three of these functions do not return false on
error as they should if the stream is not flushed successfully. Yipes!
https://bugs.php.net/bug.php?id=60110
Am I missing something here?
It's especially bad with, say, an S3 stream wrapper that wants to
write the whole thing as one HTTP request, but it could bite you with
plain old files too.
--
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.com