Skip to content

Commit 1bb4a03

Browse files
committed
Drop support for Windows XP
1 parent da9d1d6 commit 1bb4a03

File tree

14 files changed

+42
-547
lines changed

14 files changed

+42
-547
lines changed

dtool/src/dtoolbase/dtoolbase.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@
118118
#ifdef _WIN32_WINNT
119119
#undef _WIN32_WINNT
120120
#endif
121-
#define _WIN32_WINNT 0x0502
121+
#define _WIN32_WINNT 0x0600
122122

123123
#ifdef __cplusplus
124124
#ifndef __STDC_LIMIT_MACROS

dtool/src/dtoolbase/mutexWin32Impl.I

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,40 +11,28 @@
1111
* @date 2006-02-07
1212
*/
1313

14-
/**
15-
*
16-
*/
17-
INLINE MutexWin32Impl::
18-
~MutexWin32Impl() {
19-
// If the lock has been contended, and we use the Windows XP implementation,
20-
// we have a handle to close. Otherwise, this field will be null.
21-
if (_lock[1] != nullptr) {
22-
CloseHandle(_lock[1]);
23-
}
24-
}
25-
2614
/**
2715
*
2816
*/
2917
INLINE void MutexWin32Impl::
3018
lock() {
31-
_funcs._lock(_lock);
19+
AcquireSRWLockExclusive(&_lock);
3220
}
3321

3422
/**
3523
*
3624
*/
3725
INLINE bool MutexWin32Impl::
3826
try_lock() {
39-
return (_funcs._try_lock(_lock) != 0);
27+
return (TryAcquireSRWLockExclusive(&_lock) != 0);
4028
}
4129

4230
/**
4331
*
4432
*/
4533
INLINE void MutexWin32Impl::
4634
unlock() {
47-
_funcs._unlock(_lock);
35+
ReleaseSRWLockExclusive(&_lock);
4836
}
4937

5038
/**

0 commit comments

Comments
 (0)