| 485 | } |
| 486 | |
| 487 | static 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 | |
| 509 | static int fixup_stat(void** param) |
| 510 | { |
no test coverage detected