View Single Post
Old 11-23-2009, 07:30 PM  
quantum-x
Confirmed User
 
quantum-x's Avatar
 
Join Date: Feb 2002
Location: ICQ: 251425 Fr/Au/Ca
Posts: 6,863
Quote:
Originally Posted by rowan View Post
It's happened to me. ;) When you open a file for write it's first truncated, so if there's something else writing at that time, or the file system allows a truncate but not write when it's chock full, you'll end up with a 0 byte file. For a rotating buffer like this it's probably better to use a pointer and save that in a separate file - at least if that gets trashed then it just starts at 0 again...
As with anything when you write to the filesystem. You should be / your host should be monitoring disc space anyhow.

If you're out of space PHP will probaby grind itself to death when attempting to even run
quantum-x is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote