[PATCH]add maat_state_get_last_hit_group_id_cnt API
This commit is contained in:
@@ -123,6 +123,8 @@ size_t compile_state_get_last_hit_group_id(struct compile_state *compile_state,
|
||||
long long *group_id_arary,
|
||||
size_t array_size);
|
||||
|
||||
size_t compile_state_get_last_hit_group_id_cnt(struct compile_state *compile_state);
|
||||
|
||||
int compile_state_get_compile_table_id(struct compile_state *compile_state,
|
||||
long long compile_id);
|
||||
|
||||
|
||||
@@ -2151,4 +2151,13 @@ int maat_state_get_last_hit_group_ids(struct maat_state *state,
|
||||
|
||||
return compile_state_get_last_hit_group_id(state->compile_state,
|
||||
group_id_array, array_size);
|
||||
}
|
||||
|
||||
size_t maat_state_get_last_hit_group_id_cnt(struct maat_state *state)
|
||||
{
|
||||
if (NULL == state || NULL == state->compile_state) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
return compile_state_get_last_hit_group_id_cnt(state->compile_state);
|
||||
}
|
||||
@@ -2578,6 +2578,11 @@ size_t compile_state_get_last_hit_group_id(struct compile_state *compile_state,
|
||||
return i;
|
||||
}
|
||||
|
||||
size_t compile_state_get_last_hit_group_id_cnt(struct compile_state *compile_state)
|
||||
{
|
||||
return utarray_len(compile_state->last_hit_group_ids);
|
||||
}
|
||||
|
||||
size_t compile_state_get_direct_hit_groups(struct compile_state *compile_state,
|
||||
struct maat_hit_group *group_array,
|
||||
size_t array_size)
|
||||
|
||||
Reference in New Issue
Block a user