比方说,我有这样的创建ç线程
#####
typeofthread1
#####
typeofthread2
等组成的文本文件......在我的主要
我想读的那个文件,得到的字符串typeofthread1,typeofthread2并使用
pthread_t threads[NUM_THREADS];
for (i=0;i<NUM_THREADS;i++)
pthread_create(&threads[i], NULL, -> HERE <- , void * arg);
我怎样才能把创建不同的线程刚读typeofthread1,typeofthread2串入 - >这里< - 使主要创建两个线程指向两个不同的线程原型?
我想这样做,因为我想创建一个用于创建不同类型的线,这取决于我想要做一个程序,并选择从文本文件(排序的配置文件)
任何建议?