a993c777d5a11766f3f8ba3c3482be840e1bc6f2
1 #include <unistd.h> // pour sleep
2 #include <pthread.h> // pthread_create, pthread_join, pthread_exit
5 static void* fonction(void* args
) {
6 printf("pid du thread fils = %d\n", getpid());
14 printf("pid de main = %d\n", getpid());
15 pthread_create(&thread
, NULL
, &fonction
, NULL
);