diff options
Diffstat (limited to 'plugin')
| -rw-r--r-- | plugin/business/ssl-policy/src/ssl_policy.cpp | 1 | ||||
| -rw-r--r-- | plugin/business/tsg-http/src/tsg_http.cpp | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/plugin/business/ssl-policy/src/ssl_policy.cpp b/plugin/business/ssl-policy/src/ssl_policy.cpp index 6586941..856c0e7 100644 --- a/plugin/business/ssl-policy/src/ssl_policy.cpp +++ b/plugin/business/ssl-policy/src/ssl_policy.cpp @@ -213,6 +213,7 @@ static void profile_param_new_cb(const char *table_name, const char *key, const cJSON_Delete(json); free(json_str); + return; error_out: if (json) diff --git a/plugin/business/tsg-http/src/tsg_http.cpp b/plugin/business/tsg-http/src/tsg_http.cpp index 4e365b1..4a177b6 100644 --- a/plugin/business/tsg-http/src/tsg_http.cpp +++ b/plugin/business/tsg-http/src/tsg_http.cpp @@ -450,7 +450,7 @@ char* str_unescape(char* s) unsigned char action_type_str2idx(const char *action_str) { - const char * action_name[__PX_ACTION_MAX]; + const char * action_name[__PX_ACTION_MAX] ={0}; action_name[PX_ACTION_NONE] = "none"; action_name[PX_ACTION_MONIT] = "monitor"; action_name[PX_ACTION_INTERCEPT] = "intercept"; @@ -468,7 +468,7 @@ unsigned char action_type_str2idx(const char *action_str) int action = 0; for ( action = PX_ACTION_NONE; action < __PX_ACTION_MAX; action++) { - if (0 == strcasecmp(action_str, action_name[action])) + if (action_name[action] != NULL && 0 == strcasecmp(action_str, action_name[action])) break; } return action; |
