Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Aug 1998 05:55:13 +0000 (GMT)
From:      Terry Lambert <tlambert@primenet.com>
To:        julian@whistle.com (Julian Elischer)
Cc:        oppermann@pipeline.ch, hackers@FreeBSD.ORG
Subject:   Re: sendfile() API?
Message-ID:  <199808170555.WAA20672@usr09.primenet.com>
In-Reply-To: <Pine.BSF.3.95.980816130634.7671A-100000@current1.whistle.com> from "Julian Elischer" at Aug 16, 98 01:08:12 pm

next in thread | previous in thread | raw e-mail | index | archive | help
> I've been having a quick discussion with linus re: the sendfile()
> API that he is puting in linux..
> I will be implementing an identical API on freebsd for
> SAMBA to use.
> warning: he has decided to not use an API identical to HPUX
> but it will give similar (expanded) functionality.

My main problem with sendfile(), as it is generally used, I
presume, being ripped directly from the sample POP3 implementation
on the NT SDK CDROM, is data interpretation.

In order to make sendfile useful, it is necessary to store the
file with CRLF line delimiters and the "." character pre-bytestuffed
if it occors on a line by itself.  Like the one that follows:

.

The problem here is that no processing of file contents is allowed.

This greatly limits the utility of such an interface.

The any-fd-to-any-fd suggestion is actually rather bogus; it is
only useful on cached data; that is, recieving or sending a file
would be useful, but going from one network connection to another
would be merely an extra two copies, when a sperate optimization
to turn inbound mbuf's into outbound mbuf's would  save all but
the copies to and from controller memory.

Storing files with wire format contents is OK, even for mail files,
until you try to use bot a POP3 and an IMAP and a local application
client on the mail file.  Then it breaks down horrendously.

I would also hate to have to edit CRLF into all of my WWW pages,
which would be required.  8-(.


					Terry Lambert
					terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199808170555.WAA20672>