From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <599f06db0611201557k7945620fq848f67450ec63e06@mail.gmail.com> Date: Tue, 21 Nov 2006 00:57:44 +0100 From: "Gorka guardiola" To: "Fans of the OS Plan 9 from Bell Labs" <9fans@cse.psu.edu> Subject: Re: [9fans] echo -n In-Reply-To: <8ccc8ba40611201522g2514b38fn464a2b9d721daeeb@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <8ccc8ba40611201116r89eba04m32cf9d487a02ceb5@mail.gmail.com> <5c2bf4a5c8ff68ef5e1bfd2db024e300@plan9.jp> <8ccc8ba40611201305u114a86fboa765b4dd87a95b4e@mail.gmail.com> <8ccc8ba40611201411o35a3f282kf10d4bcf5f4d7bc1@mail.gmail.com> <599f06db0611201514u26ac129axa8b21894a17f6d00@mail.gmail.com> <8ccc8ba40611201522g2514b38fn464a2b9d721daeeb@mail.gmail.com> Topicbox-Message-UUID: e3ce466e-ead1-11e9-9d60-3106f5b1d025 On 11/21/06, Francisco J Ballesteros wrote: > Yes, but, what does it mean to write zero bytes? > I know, I know. > But my point is, does it make sense? I am not particularly disturbed by a 0 write meaning "send an eof" as Russ said, or the idea of an empty message, which does not necessarily mean the pipe is closed. It is just a matter of conventions. > If you want a write of something weird to mean something, you might > just use a write of something weird, or a control operation kept appart. Yes, I agree with you, you can send a special character or message. I do not think zero sized messages are impossible to survive without except... ... what about a network connection/files?. I think that may be a better case for or against zero writes. Because a network connections should not be different from pipes, should they?. How do you send (or receive) an empty datagram?. Does it make sense?. Do other os's do it? because we have to cope with it in that case too. > > A related question, can we create a file with an empty name? > Is what happens a bug or a feature? > Dunno, is it really related?. If you mean an empty string, that should be ok shouldn't it?. You should be able to manipulate a file with name '\0' without problem I guess. I haven't tried or read the code dealing with this though, to answer the question. -- - curiosity sKilled the cat