This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: help in tcp/ip stack !!!
- To: wangwei <wangw at start dot com dot cn>
- Subject: Re: [ECOS] help in tcp/ip stack !!!
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Tue, 05 Jun 2001 13:53:40 +0100
- Cc: ecos-discuss at sources dot redhat dot com
- Organization: Red Hat UK Ltd.
- References: <002e01c0ed5a$f6e339a0$592da8c0@start.com.cn>
wangwei wrote:
>
> Hi,all
> help me !!
> I make a tcp server in ecos. when client connect with it , appliaction
> dynamically create a thread to communicate with client.
> the client is running in linux, and can be run in background .
> At normal, the server can running stably.
> When I make a shell to run lots of client program in background,more than 30
> clients,the server in ecos give "EXH 4" error.
> In this application, My memory in ecos is more than 3M ,there is enough
> memory for malloc. And when thread which run server program is ended, the
> memory it used can be free .So I think memory cann't cause this problem.
>
> I had met the "EXH 4" error before . When I try ipaq nanox package in ecos ,
> it call nanosleep() in a no posix thread , and cause a "EXH 4" error.
> so I suspect it is caused by the same reason .but I can't find out .
That means you got an exception.
I had a quick look at your code and I believe the problem is that you are
using cyg_thread_kill() and then freeing the threads memory. You almost
certainly want to use cyg_thread_delete() instead.
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/