Skip to content

Commit

Permalink
modules/dialog_ng: changed stats to use native counters instead
Browse files Browse the repository at this point in the history
	- suggested by Olle
  • Loading branch information
jaybeepee committed Feb 5, 2015
1 parent 790b42c commit 23b4d93
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions modules/dialog_ng/dlg_handlers.c
Expand Up @@ -556,6 +556,7 @@ static void dlg_onreply(struct cell* t, int type, struct tmcb_params *param) {
ref_dlg(dlg, 1);
}

counter_add(dialog_ng_cnts_h.early, -1);
counter_inc(dialog_ng_counters_h.active);
run_dlg_callbacks(DLGCB_CONFIRMED, dlg, req, rpl, DLG_DIR_UPSTREAM, 0);

Expand Down
2 changes: 1 addition & 1 deletion modules/dialog_ng/dlg_ng_stats.c
Expand Up @@ -2,7 +2,7 @@

struct dialog_ng_counters_h dialog_ng_cnts_h;

/* sctp counters definitions */
/* dialog_ng counters definitions */
counter_def_t dialog_ng_cnt_defs[] = {
{&dialog_ng_cnts_h.active, "active", 0, 0, 0,
"number of current active (answered) dialogs"},
Expand Down
5 changes: 3 additions & 2 deletions modules/dialog_ng/dlg_ng_stats.h
Expand Up @@ -10,7 +10,8 @@ struct dialog_ng_counters_h {
counter_handle_t processed;

};
#endif /* DIALOG_NG_STATS_H */

int dialog_ng_stats_init();
void dialog_ng_stats_destroy();
void dialog_ng_stats_destroy();

#endif /* DIALOG_NG_STATS_H */

0 comments on commit 23b4d93

Please sign in to comment.