This is the mail archive of the
ecos-patches@sourceware.org
mailing list for the eCos project.
Re: fixed thread names with posix pthreads
- From: Gary Thomas <gary at mlbassoc dot com>
- To: Stefan Sommerfeld <sommerfeld at mikrom dot de>
- Cc: eCos patches <ecos-patches at ecos dot sourceware dot org>
- Date: Fri, 21 Oct 2005 08:59:47 -0600
- Subject: Re: fixed thread names with posix pthreads
- Organization: MLB Associates
- References: <005401c5d64c$39e402f0$152ca8c0@nullnullsix>
On Fri, 2005-10-21 at 16:32 +0200, Stefan Sommerfeld wrote:
> Hi,
>
> There was the zero termination missing with the thread name in
> pthread_create().
Why rewrite the whole loop (and make it more complicated)?
It would be sufficient to just add one line to put in the
termination character. Just add this line after the for loop:
name[i] = '\0';
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------