com php-src: Store errors for some OpenSSL RAND handling: ext/openssl/openssl.c

From: Date: Sun, 10 Jan 2016 18:28:01 +0000
Subject: com php-src: Store errors for some OpenSSL RAND handling: ext/openssl/openssl.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-92465@lists.php.net to get a copy of this message
Commit: b5c990c39b0ce0cba25d90226f923c6f6a17050e Author: Jakub Zelenka <bukka@php.net> Sun, 10 Jan 2016 18:28:01 +0000 Parents: fb3a7e0ef423af6d4dc6cfdeb5714db7af4e58dd Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b5c990c39b0ce0cba25d90226f923c6f6a17050e Log: Store errors for some OpenSSL RAND handling Changed paths: M ext/openssl/openssl.c Diff: diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 0e8be09..ea0a8a5 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -1077,6 +1077,7 @@ static int php_openssl_load_rand_file(const char * file, int *egdsocket, int *se } if (file == NULL || !RAND_load_file(file, -1)) { if (RAND_status() == 0) { + php_openssl_store_errors(); php_error_docref(NULL, E_WARNING, "unable to load random state; not enough random data!"); return FAILURE; } @@ -1101,6 +1102,7 @@ static int php_openssl_write_rand_file(const char * file, int egdsocket, int see file = RAND_file_name(buffer, sizeof(buffer)); } if (file == NULL || !RAND_write_file(file)) { + php_openssl_store_errors(); php_error_docref(NULL, E_WARNING, "unable to write random state"); return FAILURE; }

« previous php.cvs (#92465) next »