From: Michael Jerris Date: Thu, 21 May 2009 22:17:39 +0000 (+0000) Subject: core: fix handle leak in switch_thread_self on windows (FSCORE-371) X-Git-Tag: v1.0.4~784 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ffa7c709e19242bf9ef118bec5367020ae9e6387;p=thirdparty%2Ffreeswitch.git core: fix handle leak in switch_thread_self on windows (FSCORE-371) git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13421 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/switch_apr.c b/src/switch_apr.c index 55ddea5cd0..e2e33554b7 100644 --- a/src/switch_apr.c +++ b/src/switch_apr.c @@ -71,7 +71,11 @@ SWITCH_DECLARE(switch_thread_id_t) switch_thread_self(void) { +#ifndef WIN32 return apr_os_thread_current(); +#else + return (GetCurrentThreadId()); +#endif } SWITCH_DECLARE(void) switch_pool_clear(switch_memory_pool_t *p)