1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-10 05:13:38 +00:00

1. Added ability to spawn joinable threads on linux

2. Added ILibThread_TimedJoin()
This commit is contained in:
Bryan Roe
2020-04-20 21:51:55 -07:00
parent 71d4b1edca
commit 28db019101
4 changed files with 57 additions and 19 deletions

View File

@@ -1432,8 +1432,14 @@ extern void ILib_POSIX_CrashHandler(int code);
\ingroup ILibParsers
*@{
*/
void* ILibSpawnNormalThread(voidfp1 method, void* arg);
void* ILibSpawnNormalThreadEx(voidfp1 method, void* arg, int detached);
#define ILibSpawnNormalThread(method, arg) ILibSpawnNormalThreadEx(method, arg, 1)
void ILibThread_Join(void *thr);
int ILibThread_TimedJoin(void *thr, uint32_t timeout);
#ifndef WIN32
int ILibThread_TimedJoinEx(void *thr, struct timespec* timeout);
struct timespec *ILibThread_ms2ts(uint32_t ms, struct timespec *ts);
#endif
void ILibEndThisThread();
#ifdef WIN32
void ILibHandle_DisableInherit(HANDLE *h);