From b360726c32dce8f0a72f79eafe67567f78bd54b7 Mon Sep 17 00:00:00 2001 From: zhengchao Date: Thu, 21 Dec 2017 09:36:13 +0800 Subject: [PATCH] =?UTF-8?q?1)=E4=BF=AE=E5=A4=8D=E8=A7=A3=E5=AF=86=E5=A4=B1?= =?UTF-8?q?=E8=B4=A5=E6=97=B6=EF=BC=8C=E6=9C=AA=E5=85=B3=E9=97=AD=E8=A1=A8?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E5=8F=A5=E6=9F=84=E7=9A=84bug=EF=BC=9B2?= =?UTF-8?q?=EF=BC=89=E5=88=A0=E9=99=A4=E9=83=A8=E5=88=86=E8=BF=90=E8=A1=8C?= =?UTF-8?q?=E6=97=A5=E5=BF=97=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/entry/Maat_rule.cpp | 13 +++---------- src/entry/config_monitor.cpp | 6 ++++-- 2 files changed, 7 insertions(+), 12 deletions(-) diff --git a/src/entry/Maat_rule.cpp b/src/entry/Maat_rule.cpp index f5e845d..c80d6de 100644 --- a/src/entry/Maat_rule.cpp +++ b/src/entry/Maat_rule.cpp @@ -30,7 +30,7 @@ #include "stream_fuzzy_hash.h" #include "gram_index_engine.h" -int MAAT_FRAME_VERSION_2_1_20171206_dev=1; +int MAAT_FRAME_VERSION_2_1_20171221_dev=1; const char* CHARSET_STRING[]={"NONE","gbk","big5","unicode","utf8","bin", "unicode_ascii_esc","unicode_ascii_aligned","unicode_ncr_dec","unicode_ncr_hex","url_encode_gb2312","url_encode_utf8",""}; @@ -2056,11 +2056,7 @@ int del_region_rule(struct _Maat_table_info_t* table,int region_id,int group_id, { HASH_delete_by_id(maat_scanner->group_hash,group_id); garbage_bagging(GARBAGE_GROUP_RULE, group_rule, maat_scanner->tomb_ref); - MESA_handle_runtime_log(logger,RLOG_LV_DEBUG,maat_module , - "Indirectly delete group %d,last region rule has been delete,table %s region id %d ." - ,group_id - ,table->table_name[table->updating_name] - ,region_id); + } return 1; } @@ -2130,10 +2126,7 @@ void del_group_rule(struct _Maat_table_info_t* table,struct db_group_rule_t* db_ //Directly delete group id will not destroyp group_rule,it 'll be destroyed when delete this group's last region. if(group_rule->ref_cnt==0&&group_rule->region_cnt==0) { - MESA_handle_runtime_log(logger,RLOG_LV_INFO,maat_module , - "Directly delete table %s group id %d, do this when delete its last region." - ,table->table_name[table->updating_name] - ,db_group_rule->group_id); + //Directly delete table %s group id %d, do this when delete its last region. } return; } diff --git a/src/entry/config_monitor.cpp b/src/entry/config_monitor.cpp index 24f0aec..07a1e0e 100644 --- a/src/entry/config_monitor.cpp +++ b/src/entry/config_monitor.cpp @@ -382,13 +382,15 @@ int cm_read_table_file(struct cm_table_info_t* index, { if(key==NULL||strlen((const char*)key)==0) { - MESA_handle_runtime_log(logger,RLOG_LV_FATAL,module_config_monitor,"update error,no key to decrypt %s.",index->cfg_path); + MESA_handle_runtime_log(logger,RLOG_LV_FATAL,module_config_monitor,"update error, no key to decrypt %s.",index->cfg_path); + fclose(fp); return -1; } decrypt_len=decrypt_open(fp, key,index->encryp_algorithm, &decrypt_buff,logger); if(decrypt_len==0) { - MESA_handle_runtime_log(logger,RLOG_LV_FATAL,module_config_monitor,"update error,%s decrypt failed.",index->cfg_path); + MESA_handle_runtime_log(logger,RLOG_LV_FATAL,module_config_monitor,"update error, %s decrypt failed.",index->cfg_path); + fclose(fp); return -1; } read_nxt_line_from_buff(decrypt_buff, decrypt_len, &decrypt_offset, line, sizeof(line));