From 8e0d69eec140aaf9602c873040f855badda9852f Mon Sep 17 00:00:00 2001 From: zhengchao Date: Thu, 13 Jun 2019 19:53:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=89=AB=E6=8F=8F=E7=8E=B0?= =?UTF-8?q?=E5=9C=BA=E6=AD=BB=E9=94=81=E7=9A=84bug=EF=BC=8C=E9=80=9A?= =?UTF-8?q?=E8=BF=87=E5=BB=B6=E8=BF=9F=E5=88=A0=E9=99=A4=E6=96=B9=E5=BC=8F?= =?UTF-8?q?=E9=94=80=E6=AF=81compile=5Fgroup=5Frelation=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/entry/Maat_rule.cpp | 5 ++++- src/inc_internal/Maat_rule_internal.h | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/entry/Maat_rule.cpp b/src/entry/Maat_rule.cpp index eb78d9d..dbd85f8 100644 --- a/src/entry/Maat_rule.cpp +++ b/src/entry/Maat_rule.cpp @@ -1128,7 +1128,7 @@ void destroy_compile_group_relation(struct Maat_compile_group_relation * p, stru assert(p_group==NULL); } HASH_delete_by_id(scanner->compile_hash, p->compile_id); - _destroy_compile_group_relation(p); + garbage_bagging(GARBAGE_COMPILE_GOURP_RELATION, p, scanner->tomb_ref); } scan_rule_t* create_rs_str_rule(unsigned int sub_type,enum MAAT_MATCH_METHOD match_method,int is_case_sensitive,const char* string,int len,int l_offset,int r_offset) { @@ -3469,6 +3469,9 @@ void garbage_bury(MESA_lqueue_head garbage_q,int timeout,void *logger) case GARBAGE_COMPILE_RULE: destroy_compile_rule(bag->compile_rule); break; + case GARBAGE_COMPILE_GOURP_RELATION: + _destroy_compile_group_relation(bag->compile_group_relation); + break; case GARBAGE_GROUP_RULE: _destroy_group_rule(bag->group_rule); break; diff --git a/src/inc_internal/Maat_rule_internal.h b/src/inc_internal/Maat_rule_internal.h index 8013754..6c315f8 100644 --- a/src/inc_internal/Maat_rule_internal.h +++ b/src/inc_internal/Maat_rule_internal.h @@ -192,6 +192,7 @@ enum maat_garbage_type GARBAGE_SCANNER=0, GARBAGE_GROUP_RULE, GARBAGE_COMPILE_RULE, + GARBAGE_COMPILE_GOURP_RELATION, GARBAGE_BOOL_MATCHER, GARBAGE_MAP_STR2INT, GARBAGE_FOREIGN_FILE @@ -432,6 +433,7 @@ struct _maat_garbage_t struct Maat_scanner_t* scanner; struct Maat_group_inner* group_rule; struct Maat_compile_rule* compile_rule; + struct Maat_compile_group_relation * compile_group_relation; struct bool_matcher* bool_matcher; void * raw; MESA_htable_handle str2int_map;