Cygwin randomness
authorUlf Möller <ulf@openssl.org>
Sat, 19 Mar 2005 11:52:15 +0000 (11:52 +0000)
committerUlf Möller <ulf@openssl.org>
Sat, 19 Mar 2005 11:52:15 +0000 (11:52 +0000)
CHANGES
crypto/rand/rand_win.c

diff --git a/CHANGES b/CHANGES
index ef7990b3288e660b8e35755336a942d2422080f3..18b3a1a32a5459f8c8c2a552e7ee704a00d84ed9 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -4,7 +4,8 @@
 
  Changes between 0.9.6m and 0.9.6n  [XX XXX XXXX]
 
-  *) 
+  *) Use Windows randomness collection on Cygwin.
+     [Ulf Möller]
 
  Changes between 0.9.6l and 0.9.6m  [17 Mar 2004]
 
index 9e87f49872ae52113407c92fe1d7c6b73bfaac3d..fac4da1b73ea75b62307003558516acd16301415 100644 (file)
 #include <openssl/rand.h>
 #include "rand_lcl.h"
 
-#if defined(WINDOWS) || defined(WIN32)
+#if defined(WINDOWS) || defined(WIN32) || defined(__CYGWIN32__)
 #include <windows.h>
 #ifndef _WIN32_WINNT
 # define _WIN32_WINNT 0x0400
@@ -643,6 +643,7 @@ static void readtimer(void)
 
 static void readscreen(void)
 {
+#ifndef __CYGWIN32__
   HDC          hScrDC;         /* screen DC */
   HDC          hMemDC;         /* memory DC */
   HBITMAP      hBitmap;        /* handle for our bitmap */
@@ -703,6 +704,7 @@ static void readscreen(void)
   DeleteObject(hBitmap);
   DeleteDC(hMemDC);
   DeleteDC(hScrDC);
+#endif
 }
 
 #else /* Unix version */