Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 339cfa2

Browse files
committed
Fix RedisArray authentication
1 parent af7528d commit 339cfa2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

redis_array_impl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ ra_load_hosts(RedisArray *ra, HashTable *hosts, zend_string *auth, long retry_in
8383
if (!b_lazy_connect)
8484
{
8585
/* connect */
86-
if (redis_sock_server_open(redis->sock TSRMLS_CC) < 0) {
86+
if (redis_sock_server_open(redis->sock TSRMLS_CC) < 0 || (auth && redis_sock_auth(redis->sock TSRMLS_CC) < 0)) {
8787
zval_dtor(&z_cons);
8888
ra->count = ++i;
8989
return NULL;

0 commit comments

Comments
 (0)