Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpredis/phpredis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavlo Yatsukhnenko <yatsukhnenko@gmail.com>2021-04-08 08:53:36 +0300
committerPavlo Yatsukhnenko <yatsukhnenko@gmail.com>2021-04-10 21:26:29 +0300
commitb0b9dd78ef7c15af936144c1b17df1a9273d72ab (patch)
tree2632efff912ca0add7b184f1e74502f98e63eb35 /cluster_library.c
parent8eed7c7d9c87a205c30359a6d918fc1a2170c58b (diff)
[WIP] Issue #1894
Add GET option to SET command
Diffstat (limited to 'cluster_library.c')
-rw-r--r--cluster_library.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/cluster_library.c b/cluster_library.c
index f61a6704..7c455ef3 100644
--- a/cluster_library.c
+++ b/cluster_library.c
@@ -1737,6 +1737,16 @@ PHP_REDIS_API void cluster_ping_resp(INTERNAL_FUNCTION_PARAMETERS, redisCluster
CLUSTER_RETURN_BOOL(c, 1);
}
+PHP_REDIS_API void
+cluster_set_resp(INTERNAL_FUNCTION_PARAMETERS, redisCluster *c, void *ctx)
+{
+ if (ctx == NULL) {
+ cluster_bool_resp(INTERNAL_FUNCTION_PARAM_PASSTHRU, c, NULL);
+ } else {
+ cluster_bulk_resp(INTERNAL_FUNCTION_PARAM_PASSTHRU, c, NULL);
+ }
+}
+
/* 1 or 0 response, for things like SETNX */
PHP_REDIS_API void cluster_1_resp(INTERNAL_FUNCTION_PARAMETERS, redisCluster *c,
void *ctx)