Created
July 20, 2011 18:22
-
-
Save scottmac/1095554 to your computer and use it in GitHub Desktop.
OpenSSL Patch for Windows
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/crypto/rand/rand_win.c b/crypto/rand/rand_win.c | |
index 5d134e1..d74fa43 100644 | |
--- a/crypto/rand/rand_win.c | |
+++ b/crypto/rand/rand_win.c | |
@@ -383,6 +383,11 @@ int RAND_poll(void) | |
if (advapi) | |
FreeLibrary(advapi); | |
+ /* If good then the Windows Crypto API worked, this does | |
+ the same as below so skip duplicating work */ | |
+ if (good) | |
+ return (1); | |
+ | |
if ((osverinfo.dwPlatformId != VER_PLATFORM_WIN32_NT || | |
!OPENSSL_isservice()) && | |
(user = LoadLibrary(TEXT("USER32.DLL")))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment