summaryrefslogtreecommitdiff
path: root/plugins/Exchange/src/utils.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Exchange/src/utils.cpp')
-rw-r--r--plugins/Exchange/src/utils.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/plugins/Exchange/src/utils.cpp b/plugins/Exchange/src/utils.cpp
index 7f05636da4..9bf2c6277d 100644
--- a/plugins/Exchange/src/utils.cpp
+++ b/plugins/Exchange/src/utils.cpp
@@ -201,7 +201,7 @@ RECT AnchorCalcPos(HWND window, const RECT *rParent, const WINDOWPOS *parentPos,
return rChild;
}
-DWORD WINAPI CheckEmailWorkerThread(LPVOID data)
+void __cdecl CheckEmailWorkerThread(void *data)
{
mir_cslock lck(csCheck);
@@ -211,14 +211,11 @@ DWORD WINAPI CheckEmailWorkerThread(LPVOID data)
exchangeServer.Connect(bForceAttempt);
exchangeServer.Check(bForceAttempt);
-
- return 0;
}
int ThreadCheckEmail(int bForceAttempt)
{
- DWORD idThread;
- HANDLE hCheckThread = CreateThread(NULL, NULL, CheckEmailWorkerThread, (void *) bForceAttempt, 0, &idThread);
+ HANDLE hCheckThread = mir_forkthread(CheckEmailWorkerThread, (void *)bForceAttempt);
CloseHandle(hCheckThread);
return 0;