Change-Id: I2453277e2c92e53f6a6e7f8cdc6431ead66dcaff
static void *thread_function(void *data)
{
int cnt = 0;
- int test_idx = (int)data;
+ int test_idx = GPOINTER_TO_INT(data);
while (thread_sw) {
if (cnt > loop)
int i;
GThread **thread_list = (GThread **)calloc(sizeof(GThread*), N_THREADS);
for (i = 0; i < N_THREADS; i++)
- thread_list[i] = g_thread_new(NULL, thread_function, (void*)test_num);
+ thread_list[i] = g_thread_new(NULL, thread_function, GINT_TO_POINTER(test_num));
return thread_list;
}