summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--common/src/tfe_scan.cpp1
-rw-r--r--plugin/business/tsg-http/src/tsg_http.cpp8
2 files changed, 7 insertions, 2 deletions
diff --git a/common/src/tfe_scan.cpp b/common/src/tfe_scan.cpp
index 0fcc03f..7eac118 100644
--- a/common/src/tfe_scan.cpp
+++ b/common/src/tfe_scan.cpp
@@ -220,7 +220,6 @@ int tfe_scan_ip_tags(const struct tfe_stream *stream, uuid_t *result, struct maa
if(n_tag_ids == 0)
{
TFE_LOG_DEBUG(logger, "fetch src ip tags: NULL");
- return hit_cnt_ip;
}
tfe_tags_log(opt_val, n_tag_ids, "src ip", logger);
diff --git a/plugin/business/tsg-http/src/tsg_http.cpp b/plugin/business/tsg-http/src/tsg_http.cpp
index 085e7e2..82ccbb0 100644
--- a/plugin/business/tsg-http/src/tsg_http.cpp
+++ b/plugin/business/tsg-http/src/tsg_http.cpp
@@ -614,7 +614,7 @@ void policy_action_param_new(const char *table_name, const char* key, const char
{
param->hit_rule.vsys_id=item->valueint;
}
- item=cJSON_GetObjectItem(action_parameter,"insert_profile");
+ item=cJSON_GetObjectItem(action_parameter,"inject_profile");
if(item && item->type==cJSON_String)
{
param->profile_uuid_str =tfe_strdup(item->valuestring);
@@ -2398,6 +2398,12 @@ static int format_insert_rule(char *profile_uuid, struct insert_rule *rule)
{
int ret = 0;
+ if(profile_uuid == NULL)
+ {
+ ret=-1;
+ return ret;
+ }
+
struct manipulate_profile* insert_profile=get_profile_by_id("PROXY_INJECT_SCRIPT", profile_uuid);
if(insert_profile==NULL)
{