From 7f013474315073b03e617986449fda49316da169 Mon Sep 17 00:00:00 2001 From: hj-collab <101234934+hj-collab@users.noreply.github.com> Date: Tue, 30 May 2023 18:10:37 +0530 Subject: [PATCH 1/3] Update object-cache.php Connect via unix socket instead of filesystem to be compatible with php open_basedir restrictions. --- object-cache.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/object-cache.php b/object-cache.php index 05c6526..1093451 100644 --- a/object-cache.php +++ b/object-cache.php @@ -1256,7 +1256,7 @@ public function build_client_parameters( $redis_server ) { } } - if ( file_exists( $redis_server['host'] ) && 'socket' === filetype( $redis_server['host'] ) ) { // unix socket connection. + if (strpos($redis_server['host'], 'unix:///') === 0) { // Unix socket connection. // port must be null or socket won't connect. $port = null; } else { // tcp connection. From caeba1aca00ab4478da2f591e55b3dcdb2f29177 Mon Sep 17 00:00:00 2001 From: hj-collab <101234934+hj-collab@users.noreply.github.com> Date: Tue, 30 May 2023 18:14:55 +0530 Subject: [PATCH 2/3] Update object-cache.php Removed null on 1296 for PHP 8.1 compatibility --- object-cache.php | 1 - 1 file changed, 1 deletion(-) diff --git a/object-cache.php b/object-cache.php index 1093451..422c8c1 100644 --- a/object-cache.php +++ b/object-cache.php @@ -1293,7 +1293,6 @@ public function prepare_client_connection( $client_parameters ) { $client_parameters['port'], // $client_parameters['timeout'] is sent in milliseconds, connect() takes seconds, so divide by 1000. $client_parameters['timeout'] / 1000, - null, $client_parameters['retry_interval'] ); From 04291c3bee1f67a4427d615a1f0ad528948602e9 Mon Sep 17 00:00:00 2001 From: hj-collab <101234934+hj-collab@users.noreply.github.com> Date: Tue, 30 May 2023 18:30:35 +0530 Subject: [PATCH 3/3] null change reversed --- object-cache.php | 1 + 1 file changed, 1 insertion(+) diff --git a/object-cache.php b/object-cache.php index 422c8c1..1093451 100644 --- a/object-cache.php +++ b/object-cache.php @@ -1293,6 +1293,7 @@ public function prepare_client_connection( $client_parameters ) { $client_parameters['port'], // $client_parameters['timeout'] is sent in milliseconds, connect() takes seconds, so divide by 1000. $client_parameters['timeout'] / 1000, + null, $client_parameters['retry_interval'] );