c++ - error C2664: 'pthread_create' : cannot convert parameter 3 from 'void *(__clrcall *)(void *)' to 'void *(__cdecl *)(void *) -
i trying use pthread library.
what cause of error?
error c2664: 'pthread_create' : cannot convert parameter 3 'void *(__clrcall *)(void *)' 'void *(__cdecl *)(void *)
here's code:
pthread_create(&thread1,null,sub_m,(void *)data); void *sub_m(void* data)
make void __cdecl sub_m(void *data)
. in managed code, need proper calling convention.
Comments
Post a Comment