This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Re: __tcp_close() can't close connection in Redboot


Hi,
   thanks for replying.
After __tcp_close(),I keep calling __tcp_poll() until
state is _CLOSED. But it seems endless,even setup
reuse option to 1sec in sock,the state is still
TIME_WAIT..,

Have you met this situation before?
Could force to destory the state to _CLOSED?
If so,is there any potential problem?

thank you
Sam

 
--- Gary Thomas <gary@mlbassoc.com> 弧

> On Wed, 2005-10-12 at 08:34 -0500, Grant Edwards
> wrote:
> > In gmane.os.ecos.general, you wrote:
> > 
> > > RedBoot hangs once it sees the CLOSE_WAIT
> condition.
> > 
> > I've never seen that happen.
> 
> You won't - it just won't look for another 'telnet'
> session
> when the current one closes until it's completely
> closed.
> 
> > 
> > > You need to continually call __tcp_poll() which
> will
> > > eventually flush the connection which then goes
> to CLOSED.
> > 
> > You have to continually call __tcp_poll() no
> matter what state
> > the socket is, since RedBoot is single-threaded.
> > 
> > > At that time, you can create a new connection.
> > >
> > > Note: this code is untested for more than one
> active TCP connection,
> > > so beware.
> > 
> > It worked OK for me. :)
> 
> Nice to know.
> 
> -- 
>
------------------------------------------------------------
> Gary Thomas                 |  Consulting for the
> MLB Associates              |    Embedded world
>
------------------------------------------------------------
> 
> 
> -- 
> Before posting, please read the FAQ:
> http://ecos.sourceware.org/fom/ecos
> and search the list archive:
> http://ecos.sourceware.org/ml/ecos-discuss
> 
> 


___________________________________________________  最新版 Yahoo!奇摩即時通訊 7.0 beta,免費網路電話任你打!  http://messenger.yahoo.com.tw/beta.html

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]