Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F138119961
D45976.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D45976.diff
View Options
diff --git a/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c b/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c
--- a/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c
+++ b/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c
@@ -356,7 +356,7 @@
* Note: Sometimes getentropy() can be provided but not implemented
* internally. So we need to check errno for ENOSYS
*/
-# if !defined(__DragonFly__) && !defined(__NetBSD__)
+# if !defined(__DragonFly__) && !defined(__NetBSD__) && !defined(__FreeBSD__)
# if defined(__GNUC__) && __GNUC__>=2 && defined(__ELF__) && !defined(__hpux)
extern int getentropy(void *buffer, size_t length) __attribute__((weak));
@@ -393,11 +393,12 @@
/* Linux supports this since version 3.17 */
# if defined(__linux) && defined(__NR_getrandom)
return syscall(__NR_getrandom, buf, buflen, 0);
-# elif (defined(__FreeBSD__) || defined(__NetBSD__)) && defined(KERN_ARND)
- return sysctl_random(buf, buflen);
# elif (defined(__DragonFly__) && __DragonFly_version >= 500700) \
- || (defined(__NetBSD__) && __NetBSD_Version >= 1000000000)
+ || (defined(__NetBSD__) && __NetBSD_Version >= 1000000000) \
+ || defined(__FreeBSD__)
return getrandom(buf, buflen, 0);
+# elif defined(__NetBSD__) && defined(KERN_ARND)
+ return sysctl_random(buf, buflen);
# else
errno = ENOSYS;
return -1;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 30, 1:05 AM (4 h, 19 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26369380
Default Alt Text
D45976.diff (1 KB)
Attached To
Mode
D45976: Collection of fixes for _FORTIFY_SOURCE
Attached
Detach File
Event Timeline
Log In to Comment