summaryrefslogtreecommitdiff
path: root/crypto/rand
diff options
context:
space:
mode:
authorRich Salz <rsalz@akamai.com>2016-01-31 13:08:23 -0500
committerRich Salz <rsalz@openssl.org>2016-02-09 20:13:29 -0500
commiteffaf4dee90beff07bb40f21d81352304a5e8152 (patch)
tree4bc77d1b1998e6fac62b3a5967a223376cb47111 /crypto/rand
parent1ffa8a9685e22a5a0ff1b1322df4d1720b05ce4c (diff)
downloadopenssl-new-effaf4dee90beff07bb40f21d81352304a5e8152.tar.gz
Use NON_EMPTY_TRANSLATION_UNIT, consistently.
This also closes RT 4123 Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'crypto/rand')
-rw-r--r--crypto/rand/rand_egd.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/crypto/rand/rand_egd.c b/crypto/rand/rand_egd.c
index f0d2e55a48..6f13717b5a 100644
--- a/crypto/rand/rand_egd.c
+++ b/crypto/rand/rand_egd.c
@@ -53,9 +53,14 @@
*
*/
-#include <openssl/crypto.h>
-#include <openssl/e_os2.h>
-#include <openssl/rand.h>
+#include <openssl/opensslconf.h>
+#ifdef OPENSSL_NO_EGD
+NON_EMPTY_TRANSLATION_UNIT
+#else
+
+# include <openssl/crypto.h>
+# include <openssl/e_os2.h>
+# include <openssl/rand.h>
/*-
* Query the EGD <URL: http://www.lothar.com/tech/crypto/>.
@@ -94,8 +99,6 @@
* RAND_egd() is a wrapper for RAND_egd_bytes() with numbytes=255.
*/
-#ifndef OPENSSL_NO_EGD
-
# if defined(OPENSSL_SYS_WIN32) || defined(OPENSSL_SYS_VMS) || defined(OPENSSL_SYS_MSDOS) || defined(OPENSSL_SYS_VXWORKS) || defined(OPENSSL_SYS_NETWARE) || defined(OPENSSL_SYS_VOS) || defined(OPENSSL_SYS_UEFI)
int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes)
{
@@ -288,8 +291,4 @@ int RAND_egd(const char *path)
# endif
-#else /* OPENSSL_NO_EGD */
-# if PEDANTIC
-static void *dummy = &dummy;
-# endif
#endif