From da52d77bd9fd5040f35b44b2accad2d0819b298e Mon Sep 17 00:00:00 2001 From: zhengchao Date: Sat, 8 Dec 2018 16:43:07 +0600 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=93=8D=E4=BD=9Credis?= =?UTF-8?q?=E9=94=99=E8=AF=AF=E5=A4=84=E7=90=86=E7=9A=84=E7=AC=94=E8=AF=AF?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/entry/Maat_command.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/entry/Maat_command.cpp b/src/entry/Maat_command.cpp index 72db44b..1f1390a 100644 --- a/src/entry/Maat_command.cpp +++ b/src/entry/Maat_command.cpp @@ -1224,7 +1224,7 @@ int exec_serial_rule(redisContext* ctx,struct serial_rule_t* s_rule, unsigned in unsigned int max_redis_batch=1*1024, batch_cnt=0; int renew_allowed=0,last_failed=-1; redisReply*transaction_reply=NULL,*p=NULL; - unsigned int i=0; + unsigned int i=0, rule_seq=0; unsigned int multi_cmd_cnt=0, success_cnt=0; const int MAX_REDIS_OP_PER_SRULE=8; @@ -1268,12 +1268,13 @@ int exec_serial_rule(redisContext* ctx,struct serial_rule_t* s_rule, unsigned in { continue; } + rule_seq=expected_reply[i].srule_seq; MESA_handle_runtime_log(logger,RLOG_LV_FATAL,maat_command ,"%s %s %d failed, rule id maybe conflict or not exist." - ,rm_op_str[s_rule[i].op] - ,s_rule[i].table_name,s_rule[i].rule_id); + ,rm_op_str[s_rule[rule_seq].op] + ,s_rule[rule_seq].table_name,s_rule[rule_seq].rule_id); success_cnt--; - last_failed=expected_reply[i].srule_seq; + last_failed=rule_seq; } } else