From owner-freebsd-questions Sat Jul 4 23:52:28 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA27307 for freebsd-questions-outgoing; Sat, 4 Jul 1998 23:52:28 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from freebie.lemis.com (freebie.lemis.com [139.130.136.133] (may be forged)) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA27302 for ; Sat, 4 Jul 1998 23:52:23 -0700 (PDT) (envelope-from grog@freebie.lemis.com) Received: (from grog@localhost) by freebie.lemis.com (8.9.0/8.9.0) id QAA18102; Sun, 5 Jul 1998 16:22:03 +0930 (CST) Message-ID: <19980705162202.H18970@freebie.lemis.com> Date: Sun, 5 Jul 1998 16:22:02 +0930 From: Greg Lehey To: joelh@gnu.org Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Portability of scatter / gather References: <199807040356.WAA14496@detlev.UUCP> <19980704141243.B358@freebie.lemis.com> <199807040525.AAA15330@detlev.UUCP> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.91.1i In-Reply-To: <199807040525.AAA15330@detlev.UUCP>; from Joel Ray Holveck on Sat, Jul 04, 1998 at 12:25:14AM -0500 WWW-Home-Page: http://www.lemis.com/~grog Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-41-739-7062 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Saturday, 4 July 1998 at 0:25:14 -0500, Joel Ray Holveck wrote: >>> On all BSD systems, is it the case that an item written with writev >>> can be read with read without translation, or does readv have to be >>> used? >> readv and writev are just ways of transferring the data. After it is >> onn the medium, you can't tell how it got there. So yes, you can read >> it without translation. > > (Thanks also to Julian for his quick response.) > > How about mixing send and read, or write and recv? Are these > equivilent on a socket if flags == 0? You can tell that this is a tougher question, can't you? I don't have the time to check through the code on this one. On the whole, it sounds like a bad idea to mix implementations. readv and read are really the same interface to a different implementation, but sockets involve a completely different way of approaching things. I'd guess that it would be dangerous to mix the calls even if it did work now: there's no guarantee that it would stay that way. Greg -- See complete headers for address and phone numbers finger grog@lemis.com for PGP public key To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message