On 2005-05-27, Peter Hansen <[EMAIL PROTECTED]> wrote:
> Roy Smith wrote:
>> gabor <[EMAIL PROTECTED]> wrote:
>> On the other hand, you said that each process will be writing a single line
>> of output at a time. If you call flush() after each message is written,
>> that should be enough to ensure that the each line gets written in a single
>> write system call, which in turn should be good enough to ensure that
>> individual lines of output are not scrambled in the log file.
>
> Unfortunately this assumes that the open() call will always succeed,
> when in fact it is likely to fail sometimes when another file has
> already opened the file but not yet completed writing to it, AFAIK.
Not in my experience. At least under Unix, it's perfectly OK
to open a file while somebody else is writing to it. Perhaps
Windows can't deal with that situation?
--
Grant Edwards grante Yow! FOOLED you! Absorb
at EGO SHATTERING impulse
visi.com rays, polyester poltroon!!
--
http://mail.python.org/mailman/listinfo/python-list