Answers for "pthread_create definition"

C
0

pthread_create

pthread_t tid; //declaration of thread id
pthread_create(&tid, NULL, &routine, NULL); 
//routine is a function that takes in void pointer and returns a void pointer
pthread_join(tid)
Posted by: Guest on February-24-2022
0

pthread_create

#include <pthread.h>

       int pthread_create(pthread_t *thread, const pthread_attr_t *attr,
                          void *(*start_routine) (void *), void *arg);

       Compile and link with -pthread.
Posted by: Guest on November-09-2020

Code answers related to "pthread_create definition"

Code answers related to "C"

Browse Popular Code Answers by Language