On Thu, Feb 7, 2019, 8:07 AM Girgias <george.bany...@gmail.com wrote:

>
> The most common case which comes to mind is to suppress erros while file
> reading.
> Because even if you check a file exists it could be deleted inbetween the
> check and the
> read command. As you can see this is even written in the documentation [1]
>
> Best regards
>
> George Peter Banyard
>
> [1] https://secure.php.net/manual/en/function.fopen.php
>

That is one the cases I meant. Also this is a bug in the user code. I can
imagine doing it on purpose for performance reasons (if the file is
created/deleted by other apps) tho'.
 flock is what should be used here.

best,
Pierre

>
>

Reply via email to