PR: 2372
authorDr. Stephen Henson <steve@openssl.org>
Thu, 18 Nov 2010 12:30:01 +0000 (12:30 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Thu, 18 Nov 2010 12:30:01 +0000 (12:30 +0000)
Submitted by: "W.C.A. Wijngaards" <wouter@nlnetlabs.nl>
Reviewed by: steve

Fix OpenBSD compilation failure.

crypto/rand/randfile.c

index 678b0fe..f9b709e 100644 (file)
@@ -310,7 +310,7 @@ const char *RAND_file_name(char *buf, size_t size)
         * to something hopefully decent if that isn't available. 
         */
 
-       if (!ok)
+       if (!buf[0])
                if (BUF_strlcpy(buf,"/dev/arandom",size) >= size) {
                        return(NULL);
                }