POSIX says never to compare pthread_t directly

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16501 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Mathieu Rene committed 2010-01-24 19:23:58 +00:00
1 parent 4f39fe92ab
commit 62341a9526
3 files changed
+17 -4

No files matched your search

+10
View File
@@ -79,6 +79,16 @@ SWITCH_DECLARE(switch_thread_id_t) switch_thread_self(void)
#endif
}
SWITCH_DECLARE(int) switch_thread_equal(switch_thread_id_t tid1, switch_thread_id_t tid2)
{
#ifdef WIN32
return (tid1 == tid2);
#else
return apr_os_thread_equal(tid1, tid2);
#endif
}
SWITCH_DECLARE(void) switch_pool_clear(switch_memory_pool_t *p)
{
apr_pool_clear(p);