16 Sep
2011
16 Sep
'11
7:19 p.m.
Hi, On Fri Sep 16, 2011 at 12:40:09 +0400, Ivan Loskutov wrote:
On Thu, Sep 15, 2011 at 8:40 PM, Adam Lackorzynski < Thanks for patch. It fixed issue for my test program. Also error does not occur if thread created with attribute PTHREAD_CREATE_DETACHED. But if thread detached in main then i have same error.
Code: printf("new loop...\n"); pthread_create(&t1, NULL, thread, (void*)1); res = pthread_detach(&t1); printf("Detach thread 1 (%d)\n", res); pthread_create(&t2, NULL, thread, (void*)2); res = pthread_detach(&t2);
pthread_detach does not take a pointer of pthread_t, just pthread_t. Adam -- Adam adam@os.inf.tu-dresden.de Lackorzynski http://os.inf.tu-dresden.de/~adam/