vty: Prepend VTY output of counters for better visual separation.

Before this patch rate counters started right after trunk information
with no visual separation which was quite confusing. We're adding
a new line and a header to warn a user of the section change.

Change-Id: I3943def03ab821b05ac597f40bdfa4a3a71ddca3
This commit is contained in:
Alexander Chemeris 2020-05-05 17:15:21 +03:00
parent eebbf2b1fc
commit dab89af070
1 changed files with 4 additions and 0 deletions

View File

@ -262,6 +262,10 @@ static void dump_trunk(struct vty *vty, struct mgcp_trunk_config *cfg, int show_
vty_out(vty, "%s", VTY_NEWLINE);
}
if (show_stats) {
vty_out(vty, "%s", VTY_NEWLINE);
vty_out(vty, "Rate counters:%s", VTY_NEWLINE);
}
if (show_stats && cfg->mgcp_crcx_ctr_group) {
vty_out(vty, " %s:%s", cfg->mgcp_crcx_ctr_group->desc->group_description, VTY_NEWLINE);
vty_out_rate_ctr_group_fmt(vty, " %25n: %10c (%S/s %M/m %H/h %D/d) %d", cfg->mgcp_crcx_ctr_group);