From fb0fec7c1c2642d9998cfb5645964b2a59be1726 Mon Sep 17 00:00:00 2001 From: Anders Broman Date: Thu, 15 Mar 2012 14:33:04 +0000 Subject: If we have one ISB, display the droped count from it. svn path=/trunk/; revision=41561 --- summary.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'summary.c') diff --git a/summary.c b/summary.c index cd8abefc4e..b50cfb63c1 100644 --- a/summary.c +++ b/summary.c @@ -185,6 +185,7 @@ summary_fill_in_capture(capture_file *cf,capture_options *capture_opts, summary_ guint i; wtapng_iface_descriptions_t* idb_info; wtapng_if_descr_t wtapng_if_descr; + wtapng_if_stats_t *if_stats; while (st->ifaces->len > 0) { iface = g_array_index(st->ifaces, iface_options, 0); @@ -221,6 +222,13 @@ summary_fill_in_capture(capture_file *cf,capture_options *capture_opts, summary_ iface.snap = wtapng_if_descr.snap_len; iface.has_snap = (iface.snap != 65535); iface.linktype = wtapng_if_descr.link_type; + if(wtapng_if_descr.num_stat_entries == 1){ + /* dumpcap only writes one ISB, only handle that for now */ + if_stats = &g_array_index(wtapng_if_descr.interface_statistics, wtapng_if_stats_t, 0); + iface.drops_known = TRUE; + iface.drops = if_stats->isb_ifdrop; + iface.isb_comment = if_stats->opt_comment; + } g_array_append_val(st->ifaces, iface); } g_free(idb_info); -- cgit v1.2.1