Skip to content

Commit 9612185

Browse files
committed
Fixes bcit-ci#6164
Uses the fix provided in bcit-ci#6164, and additionally, the default value in Cache_redis.php
1 parent 3e5d109 commit 9612185

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

system/libraries/Cache/drivers/Cache_redis.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class CI_Cache_redis extends CI_Driver
5959
'host' => '127.0.0.1',
6060
'password' => NULL,
6161
'port' => 6379,
62-
'timeout' => 0,
62+
'timeout' => 0.0,
6363
'database' => 0
6464
);
6565

system/libraries/Session/drivers/Session_redis_driver.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ public function __construct(&$params)
157157
{
158158
$save_path['password'] = preg_match('#auth=([^\s&]+)#', $matches['options'], $match) ? $match[1] : NULL;
159159
$save_path['database'] = preg_match('#database=(\d+)#', $matches['options'], $match) ? (int) $match[1] : NULL;
160-
$save_path['timeout'] = preg_match('#timeout=(\d+\.\d+)#', $matches['options'], $match) ? (float) $match[1] : NULL;
160+
$save_path['timeout'] = preg_match('#timeout=(\d+\.\d+)#', $matches['options'], $match) ? (float) $match[1] : 0.0;
161161

162162
preg_match('#prefix=([^\s&]+)#', $matches['options'], $match) && $this->_key_prefix = $match[1];
163163
}

0 commit comments

Comments
 (0)