diff options
author | Pavlo Yatsukhnenko <yatsukhnenko@gmail.com> | 2018-11-22 23:52:39 +0300 |
---|---|---|
committer | Pavlo Yatsukhnenko <yatsukhnenko@gmail.com> | 2018-11-22 23:52:39 +0300 |
commit | 72749916140e8a0480efdea60c457f502885e6c0 (patch) | |
tree | b3f02d36a7281544f00cd6ee30730ceb5ab31c4a /cluster_library.c | |
parent | 91bd7426d539f48900ed545a105c78f02b1927b8 (diff) |
Issue #1464
Diffstat (limited to 'cluster_library.c')
-rw-r--r-- | cluster_library.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cluster_library.c b/cluster_library.c index 780c3615..3dfcbc9d 100644 --- a/cluster_library.c +++ b/cluster_library.c @@ -1384,6 +1384,11 @@ PHP_REDIS_API short cluster_send_command(redisCluster *c, short slot, const char int resp, timedout = 0; long msstart; + if (!SLOT(c, slot)) { + zend_throw_exception_ex(redis_cluster_exception_ce, 0, + "The slot %d is not covered by any node in this cluster", slot); + return -1; + } /* Set the slot we're operating against as well as it's socket. These can * change during our request loop if we have a master failure and are * configured to fall back to slave nodes, or if we have to fall back to |