mirror of
http://github.com/valkey-io/valkey
synced 2024-11-22 18:54:58 +00:00
Limit statement in RM_BlockClient() to 80 cols.
This commit is contained in:
parent
193e4acc07
commit
c94cd1d831
@ -3407,8 +3407,8 @@ RedisModuleBlockedClient *RM_BlockClient(RedisModuleCtx *ctx, RedisModuleCmdFunc
|
|||||||
RedisModuleBlockedClient *bc = c->bpop.module_blocked_handle;
|
RedisModuleBlockedClient *bc = c->bpop.module_blocked_handle;
|
||||||
|
|
||||||
/* We need to handle the invalid operation of calling modules blocking
|
/* We need to handle the invalid operation of calling modules blocking
|
||||||
* commands from Lua or MULTI. We actually create an already aborted
|
* commands from Lua or MULTI. We actually create an already aborted
|
||||||
* (client set to NULL) blocked client handle, and actually reply with
|
* (client set to NULL) blocked client handle, and actually reply with
|
||||||
* an error. */
|
* an error. */
|
||||||
bc->client = (islua || ismulti) ? NULL : c;
|
bc->client = (islua || ismulti) ? NULL : c;
|
||||||
bc->module = ctx->module;
|
bc->module = ctx->module;
|
||||||
@ -3423,8 +3423,9 @@ RedisModuleBlockedClient *RM_BlockClient(RedisModuleCtx *ctx, RedisModuleCmdFunc
|
|||||||
|
|
||||||
if (islua || ismulti) {
|
if (islua || ismulti) {
|
||||||
c->bpop.module_blocked_handle = NULL;
|
c->bpop.module_blocked_handle = NULL;
|
||||||
addReplyError(c, islua ? "Blocking module command called from Lua script" :
|
addReplyError(c, islua ?
|
||||||
"Blocking module command called from transaction");
|
"Blocking module command called from Lua script" :
|
||||||
|
"Blocking module command called from transaction");
|
||||||
} else {
|
} else {
|
||||||
blockClient(c,BLOCKED_MODULE);
|
blockClient(c,BLOCKED_MODULE);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user