Browse Source

TT#14008 show codec name in media stats

closes #1347

Change-Id: Iba796f585ae93a17347dea96f91472a60bf32b60
pull/1373/head
Ricardas Stoma 4 years ago
committed by Richard Fuchs
parent
commit
d1e2720b39
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      daemon/call_interfaces.c

+ 5
- 0
daemon/call_interfaces.c View File

@ -1691,16 +1691,21 @@ static void ng_stats_media(bencode_item_t *list, const struct call_media *m,
bencode_item_t *dict, *streams = NULL, *flags;
GList *l;
struct packet_stream *ps;
const struct rtp_payload_type *rtp_pt = NULL;
if (!list)
goto stats;
rtp_pt = __rtp_stats_codec((struct call_media *)m);
dict = bencode_list_add_dictionary(list);
bencode_dictionary_add_integer(dict, "index", m->index);
bencode_dictionary_add_str(dict, "type", &m->type);
if (m->protocol)
bencode_dictionary_add_string(dict, "protocol", m->protocol->name);
if (rtp_pt)
bencode_dictionary_add_str_dup(dict, "codec", &rtp_pt->encoding_with_params);
streams = bencode_dictionary_add_list(dict, "streams");


Loading…
Cancel
Save