diff options
author | michael-grunder <michael.grunder@gmail.com> | 2014-03-09 22:06:46 +0400 |
---|---|---|
committer | michael-grunder <michael.grunder@gmail.com> | 2014-03-09 22:06:46 +0400 |
commit | d2cb145099c2b7de548ddaa13b4619988b9c5c73 (patch) | |
tree | 90661ce3359405e13f89366bce603727234e4911 | |
parent | 2552b29aca34afeeaaed9ec1cbeedf44c6511f1a (diff) | |
parent | 0bf19719513b7aeac327a61f39bdbfdcd2b2df86 (diff) |
Merge branch 'hotfix/ra_type_check'ra_type_check
-rw-r--r-- | redis_array_impl.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/redis_array_impl.c b/redis_array_impl.c index 9f1a2238..6b125a4c 100644 --- a/redis_array_impl.c +++ b/redis_array_impl.c @@ -44,7 +44,9 @@ ra_load_hosts(RedisArray *ra, HashTable *hosts, long retry_interval, zend_bool b /* init connections */ for(i = 0; i < count; ++i) { - if(FAILURE == zend_hash_quick_find(hosts, NULL, 0, i, (void**)&zpData)) { + if(FAILURE == zend_hash_quick_find(hosts, NULL, 0, i, (void**)&zpData) || + Z_TYPE_PP(zpData) != IS_STRING) + { efree(ra); return NULL; } |