提交 015ff5d7 authored 作者: Jeff Lenk's avatar Jeff Lenk

windows fix last commit

上级 f6e591de
...@@ -625,6 +625,15 @@ struct apr_threadattr_t { ...@@ -625,6 +625,15 @@ struct apr_threadattr_t {
apr_size_t stacksize; apr_size_t stacksize;
int priority; int priority;
}; };
struct apr_thread_t {
apr_pool_t *pool;
HANDLE td;
apr_int32_t cancel;
apr_int32_t cancel_how;
void *data;
apr_thread_start_t func;
apr_status_t exitval;
};
#endif #endif
...@@ -666,7 +675,7 @@ SWITCH_DECLARE(switch_status_t) switch_thread_create(switch_thread_t ** new_thre ...@@ -666,7 +675,7 @@ SWITCH_DECLARE(switch_status_t) switch_thread_create(switch_thread_t ** new_thre
status = apr_thread_create(new_thread, attr, func, data, cont); status = apr_thread_create(new_thread, attr, func, data, cont);
#ifdef WIN32 #ifdef WIN32
if (attr->priority == SWITCH_PRI_REALTIME) { if (attr->priority == SWITCH_PRI_REALTIME) {
SetThreadPriority(new_thread, THREAD_PRIORITY_HIGHEST); SetThreadPriority(((apr_thread_t*)*new_thread)->td, THREAD_PRIORITY_HIGHEST);
} }
#endif #endif
return (switch_status_t)status; return (switch_status_t)status;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论