mirror of https://gitee.com/openkylin/libvirt.git
build: silence compiler warning on BSD
Building on 64-bit FreeBSD 8.2 complained about a cast between a pointer and a smaller integer. Going through an intermediate cast shuts up the compiler. * src/util/threads-pthread.c (virThreadSelfID): Silence a warning.
This commit is contained in:
parent
9d86cbcf5f
commit
4d970fd293
|
@ -216,7 +216,7 @@ int virThreadSelfID(void)
|
|||
tid = syscall(SYS_gettid);
|
||||
return (int)tid;
|
||||
#else
|
||||
return (int)(void *)pthread_self();
|
||||
return (int)(intptr_t)(void *)pthread_self();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue