I seem to remember the string had to be less than a certain length for this to be true. (1024, but that might be system dependant)
There are so many "if"s that this doesn't seem to reliable to me. I would at least give the user the option of using flock if I were to try to take advantage of this atomic property of syswrite.
Besides, flock will allow you to do longer operations on the log, such as shrinking in a nightly job.
In reply to atomicness of syswrite?
by ikegami
in thread Writing to a log file without colliding
by cgraf
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |