projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
88ffc8d
)
Avoid linking error for InitializeCriticalSectionAndSpinCount().
author
Soujyu Tanaka
<soujyu.tanaka@access-company.com>
Wed, 27 Mar 2019 07:15:31 +0000
(16:15 +0900)
committer
Matt Caswell
<matt@openssl.org>
Fri, 29 Mar 2019 09:51:24 +0000
(09:51 +0000)
Replace it with InitializeCriticalSection()
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/8596)
crypto/threads_win.c
patch
|
blob
|
history
diff --git
a/crypto/threads_win.c
b/crypto/threads_win.c
index 47795435be50b53456c37074add38a1445a08bea..73203834c184cbbc522a7bce29a5f453420141d4 100644
(file)
--- a/
crypto/threads_win.c
+++ b/
crypto/threads_win.c
@@
-24,11
+24,15
@@
CRYPTO_RWLOCK *CRYPTO_THREAD_lock_new(void)
return NULL;
}
+#if !defined(_WIN32_WCE)
/* 0x400 is the spin count value suggested in the documentation */
if (!InitializeCriticalSectionAndSpinCount(lock, 0x400)) {
OPENSSL_free(lock);
return NULL;
}
+#else
+ InitializeCriticalSection(lock);
+#endif
return lock;
}