This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: TCP/IP Stack packet regrouping
- To: "Trenton D. Adams" <tadams at extremeeng dot com>
- Subject: Re: [ECOS] TCP/IP Stack packet regrouping
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Mon, 16 Jul 2001 21:45:15 +0100
- Cc: 'eCos Discussion' <ecos-discuss at sourceware dot cygnus dot com>
- Organization: Red Hat UK Ltd.
- References: <000201c10e36$941324f0$090110ac@TRENT>
"Trenton D. Adams" wrote:
>
> >
> > > If not, in blocking mode it will most likely appear to
> > happen all at
> > > one time right?
> >
> > Not necessarily. read() can return early if _some_ data is
> > available.
>
> Are you saying that read () will return if ONLY some of the data is
> there, but will complete successfully if it's all there?
read() can return if some or all of the data is there. In both cases it
will return the number of bytes actually read.
> So, to summarize what you said.
>
> Sending generally will send it all at once, and there's no need for a
> loop for the outgoing buffer?
Yes.
> Receiving I should always do the loop just in case?
Yes.
Jifl
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine
Come to the Red Hat TechWorld open source conference in Brussels!
Keynotes, techie talks and exhibitions http://www.redhat-techworld.com/