I want to create a pthread using pthread_create function and pass the function name as
char *function_name="get_time";
int rc = pthread_create(&thread_arr[threadNum], NULL,
*function_name, (void *) output_cur_node->data);
Also tried using (void*)&function_name
This doesn't seem to enter the function get_time()
.
Instead, When I use below
int rc = pthread_create(&thread_arr[threadNum], NULL,
get_time, (void *) output_cur_node->data);
it works fine.
Please advise as to what is wrong here.