增加流标签
This commit is contained in:
@@ -15,7 +15,8 @@ void kni_maat_destroy(struct kni_maat_handle *handle){
|
||||
|
||||
|
||||
void compile_ex_param_new(int idx, const struct Maat_rule_t* rule, const char* srv_def_large, MAAT_RULE_EX_DATA* ad, long argl, void *argp){
|
||||
printf("call compile_ex_param_new\n");
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_new");
|
||||
if(rule->config_id == 0){
|
||||
g_maat_default_action = rule->action;
|
||||
}
|
||||
@@ -23,12 +24,14 @@ void compile_ex_param_new(int idx, const struct Maat_rule_t* rule, const char* s
|
||||
}
|
||||
|
||||
void compile_ex_param_free(int idx, const struct Maat_rule_t* rule, const char* srv_def_large, MAAT_RULE_EX_DATA* ad, long argl, void *argp){
|
||||
printf("call compile_ex_param_free\n");
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_free");
|
||||
return;
|
||||
}
|
||||
|
||||
void compile_ex_param_dup(int idx, MAAT_RULE_EX_DATA *to, MAAT_RULE_EX_DATA *from, long argl, void *argp){
|
||||
printf("call compile_ex_param_dup\n");
|
||||
void *logger = argp;
|
||||
KNI_LOG_DEBUG(logger, "call compile_ex_param_dup");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -91,8 +94,7 @@ struct kni_maat_handle* kni_maat_init(const char* profile, void *logger){
|
||||
return NULL;
|
||||
}
|
||||
struct kni_maat_handle *handle = ALLOC(struct kni_maat_handle, 1);
|
||||
ret = Maat_rule_get_ex_new_index(feather, compile_alias, compile_ex_param_new, compile_ex_param_free, compile_ex_param_dup, 0, NULL);
|
||||
printf("Maat_rule_get_ex_new_index: compile_alias is %s, ret is %d\n", compile_alias, ret);
|
||||
ret = Maat_rule_get_ex_new_index(feather, compile_alias, compile_ex_param_new, compile_ex_param_free, compile_ex_param_dup, 0, logger);
|
||||
if(ret < 0){
|
||||
KNI_LOG_ERROR(logger, "Failed at Maat_rule_get_ex_new_index, ret is %d", ret);
|
||||
kni_maat_destroy(handle);
|
||||
|
||||
Reference in New Issue
Block a user