#include "stdio.h"
#include "pthread.h" char * test( char *data); int main() { pthread_t tt; char mes[]="hello,it's work!"; int re=pthread_create(&tt,NULL,&test,mes); if(re) { printf("create thread failed\n"); exit(1); } char *b; pthread_join(tt,&b); printf("the result is %s\n",b); } char * test(char *data) { printf("%s pthread\n",data); return data; }