<html><body>
<DIV>-------------- Original message -------------- <BR>From: Jason Johnson &lt;jbjohns@libsource.com&gt; <BR><BR>&gt; David Shaffer wrote: <BR>&gt; &gt; tim Rowledge wrote: <BR>&gt; &gt;&gt; <BR>&gt; &gt;&gt; On 11-Oct-06, at 5:10 AM, David Shaffer wrote: <BR>&gt; &gt;&gt; <BR>&gt; &gt;&gt; Assuming I understand 'tread safe' in same way that you mean it, that <BR>&gt; &gt;&gt; isn't strictly correct. The problem is that the squeak model use <BR>&gt; &gt;&gt; separate positioning and read/writing calls. Thus is is quite <BR>&gt; &gt;&gt; possible (been there....) to have two processes referring to the same <BR>&gt; &gt;&gt; file and get <BR>&gt; &gt;&gt; procA -&gt; position: a <BR>&gt; &gt;&gt; procB -&gt; position: b <BR>&gt; &gt;&gt; procA -&gt; read from position (which I thought was a!) <BR>&gt; &gt;&gt; boom. <BR>&gt; &gt;&gt; <BR>&gt; &gt; I thought my meaning was the obvious one but now that I hear yours I'd <BR>&gt; &gt; agree that I was wrong. So...(let's hope the second 
try is a charm) <BR>&gt; &gt; <BR>&gt; &gt; Just a point of clarification: file I/O on a single Stream is not <BR>&gt; &gt; thread safe <BR>&gt; <BR>&gt; I know of no languages that are. If two processes are sharing the same <BR>&gt; data structure, then that will always have race conditions, unless every <BR>&gt; access is blocked by a Mutex (which, of course, you don't want). <BR></DIV>
<DIV>I think I misinterpreted this message the first time through. What David was saying is that positioning the stream to a certain location in the file doesn't help, because the other thread may come along and position it somewhere else. I don't know enough to say whether the read operation also repositions the "file pointer" in the stream, so to speak. Anyway, like I was saying in my last message, it sounds like an intermediary architecture might be necessary to make different threads play nice together with the same file.</DIV>
<DIV>&nbsp;</DIV>
<DIV>---Mark</DIV>
<DIV>&nbsp;</DIV></body></html>