Skip to content

Commit f678519

Browse files
committed
Merge branch 'master' of https://git.php.net/push/php-src
2 parents dd601e6 + 456f4a7 commit f678519

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

ext/openssl/config0.m4

+1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ if test "$PHP_OPENSSL" != "no"; then
2121

2222
AC_CHECK_LIB(ssl, DSA_get_default_method, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later]))
2323
AC_CHECK_LIB(crypto, X509_free, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later]))
24+
AC_CHECK_FUNCS([RAND_egd])
2425

2526
PHP_SETUP_OPENSSL(OPENSSL_SHARED_LIBADD,
2627
[

ext/openssl/openssl.c

+2
Original file line numberDiff line numberDiff line change
@@ -993,11 +993,13 @@ static int php_openssl_load_rand_file(const char * file, int *egdsocket, int *se
993993

994994
if (file == NULL) {
995995
file = RAND_file_name(buffer, sizeof(buffer));
996+
#ifdef HAVE_RAND_EGD
996997
} else if (RAND_egd(file) > 0) {
997998
/* if the given filename is an EGD socket, don't
998999
* write anything back to it */
9991000
*egdsocket = 1;
10001001
return SUCCESS;
1002+
#endif
10011003
}
10021004
if (file == NULL || !RAND_load_file(file, -1)) {
10031005
if (RAND_status() == 0) {

0 commit comments

Comments
 (0)