From b862d2490d6c551a81707c5f6c8c8411fe243465 Mon Sep 17 00:00:00 2001 From: liuxueli Date: Wed, 4 Aug 2021 15:15:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=9C=AA=E5=AF=B9=E7=9B=91?= =?UTF-8?q?=E6=B5=8B=E7=AD=96=E7=95=A5=E7=94=A8=E6=88=B7=E8=87=AA=E5=AE=9A?= =?UTF-8?q?=E4=B9=89=E7=A9=BA=E9=97=B4=E4=B8=BA=E7=A9=BA=E5=88=A4=E6=96=AD?= =?UTF-8?q?=E5=AF=BC=E8=87=B4=E9=87=8D=E5=90=AF=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/tsg_rule.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tsg_rule.cpp b/src/tsg_rule.cpp index 0e8b50f..8533cdc 100644 --- a/src/tsg_rule.cpp +++ b/src/tsg_rule.cpp @@ -2100,7 +2100,7 @@ int tsg_get_vlan_id_by_monitor_rule(Maat_feather_t maat_feather, struct Maat_rul } user_region=tsg_get_compile_user_region(maat_feather, &(result[i])); - if(user_region!=NULL) + if(user_region!=NULL && user_region->method_type==TSG_METHOD_TYPE_MIRRORED && user_region->mirror!=NULL) { count+=copy_vlan_id(vlan, count, user_region->mirror->vlan_id, &(result[i].config_id), 1); tsg_free_compile_user_region(&(result[i]), user_region); @@ -2133,7 +2133,7 @@ int tsg_set_vlan_id_to_tcpall(const struct streaminfo *a_stream, struct tcpall_c set_struct_project(a_stream, g_tsg_para.tcpall_project_id, (void *)_context); } - if(_context->method_type==TSG_METHOD_TYPE_MIRRORED) + if(_context->method_type==TSG_METHOD_TYPE_MIRRORED && _context->vlan!=NULL) { for(i=0; i