MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / resolve_stat

Function resolve_stat

modules/statistics/statistics.c:487–507  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

485}
486
487static int resolve_stat(str *in, str *out_group, str *out_name, int *out_grp_idx)
488{
489 module_stats *ms;
490
491 parse_groupname(in, out_group, out_name);
492 if (out_group->s) {
493 ms = get_stat_module(out_group);
494 if (!ms) {
495 LM_ERR("stat group '%.*s' must be explicitly defined "
496 "using the 'stat_groups' module parameter!\n",
497 out_group->len, out_group->s);
498 *out_grp_idx = -1;
499 return -1;
500 }
501 *out_grp_idx = ms->idx;
502 } else {
503 *out_grp_idx = -1;
504 }
505
506 return 0;
507}
508
509static int fixup_stat(void** param)
510{

Callers 4

fixup_statFunction · 0.85
w_update_statFunction · 0.85
w_reset_statFunction · 0.85
get_stat_nameFunction · 0.85

Calls 2

parse_groupnameFunction · 0.85
get_stat_moduleFunction · 0.85

Tested by

no test coverage detected