diff options
Diffstat (limited to 'src/modules/netlib/netlibopenconn.cpp')
-rw-r--r-- | src/modules/netlib/netlibopenconn.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/modules/netlib/netlibopenconn.cpp b/src/modules/netlib/netlibopenconn.cpp index b96c27aa4d..15623461c6 100644 --- a/src/modules/netlib/netlibopenconn.cpp +++ b/src/modules/netlib/netlibopenconn.cpp @@ -868,12 +868,11 @@ INT_PTR NetlibOpenConnection(WPARAM wParam, LPARAM lParam) }
if (iUPnPCleanup == 0) {
- EnterCriticalSection(&csNetlibUser);
+ mir_cslock lck(csNetlibUser);
if (iUPnPCleanup == 0) {
iUPnPCleanup = 1;
forkthread(NetlibUPnPCleanup, 0, NULL);
}
- LeaveCriticalSection(&csNetlibUser);
}
return (INT_PTR)nlc;
|