From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Wed, 1 Mar 2006 16:29:47 +0100 From: "Anselm R. Garbe" To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu> Subject: Re: [9fans] 9p and how can I know when a write is finished Message-ID: <20060301152947.GB15178@wmii.de> References: <20060301151548.GD31173@wmii.de> <3427729765b4e88fb0db2d794e3cdbc6@cat-v.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3427729765b4e88fb0db2d794e3cdbc6@cat-v.org> User-Agent: Mutt/1.5.9i Topicbox-Message-UUID: 07423a0c-ead1-11e9-9d60-3106f5b1d025 On Wed, Mar 01, 2006 at 04:20:27PM +0100, uriel@cat-v.org wrote: > > On Wed, Mar 01, 2006 at 03:29:58PM +0100, Gabriel Diaz wrote: > >> Twrite tag[2] fid[4] offset[8] count[4] data[count] > >> > >> Is there any special mark on those fields? what is > >> the man page i am missing? > > > > As far as I understood, you wait until Tclunk. > Wrong, the Tclunk is not warranteed to arrive any time soon. > > Tclunk != close() How else do you want to decide? Waiting for a write with count=0 might work by policy, but is not specified (I dunno the convenience libs of Plan 9), but I answered this as question of the protocol and not of a specific implementation of convenience libs. What might work is checking if count < iounit and guessing that no Twrite will follow... In the end you are on the safe side when waiting for Tclunk. Regards, -- Anselm R. Garbe ><>< www.ebrag.de ><>< GPG key: 0D73F361