From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: From: erik quanstrom Date: Thu, 26 Mar 2009 16:52:49 -0400 To: 9fans@9fans.net In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] 9P writes for directories Topicbox-Message-UUID: ca636062-ead4-11e9-9d60-3106f5b1d025 > It would (just as Erik pointed out). I guess I was just looking for > symmetry (if POST is really a write(*), it should translate into write > independent of whether the URI corresponds to a subdirectory or > not) and potential pitfalls that made 9P spec disallow writes on > subdirectories (and since nobody can identify any of those -- I'll > rest my case and proceed with translating POST into different > 9P messages depending on the type of the URI). the only thing that write and create have in common is the fact that they both translate to 9p messages. the beauty of create is that it is atomic. if you don't care about atomicity, you can just open if create fails. using write, the qid could not be returned and there would always be a race. since one would not have the qid, it would be impossible to tell if the race had been won. - erik