PAD: windows: fix RTL_CRITICAL_SECTION nullptr

This commit is contained in:
Gauvain 'GovanifY' Roussel-Tarbouriech 2020-12-12 20:18:31 +01:00 committed by lightningterror
parent 83e6ecb5af
commit 093e19aae6
1 changed files with 0 additions and 9 deletions

View File

@ -63,12 +63,7 @@ WndProcEater hWndButtonProc;
// Keeps the various sources for Update polling (PADpoll, PADupdate, etc) from wreaking
// havoc on each other...
#ifdef __linux__
static std::mutex updateLock;
#else
CRITICAL_SECTION updateLock;
#endif
// Used to toggle mouse listening.
u8 miceEnabled;
@ -521,11 +516,7 @@ void Update(unsigned int port, unsigned int slot)
}
// Lock prior to timecheck code to avoid pesky race conditions.
#ifdef __linux__
std::lock_guard<std::mutex> lock(updateLock);
#else
EnterScopedSection padlock(updateLock);
#endif
static unsigned int LastCheck = 0;
unsigned int t = timeGetTime();