aboutsummaryrefslogtreecommitdiffstats
path: root/summary.c
diff options
context:
space:
mode:
authorMichael Tüxen <tuexen@fh-muenster.de>2012-02-23 19:14:14 +0000
committerMichael Tüxen <tuexen@fh-muenster.de>2012-02-23 19:14:14 +0000
commitdddfe189a1c42da0a0063710de3486f2817ce35b (patch)
tree69de654c6bac1837dd796aace7e93149c9898978 /summary.c
parent286f3425e7aa27b8e9142ef2a5679a58e6feb518 (diff)
Fix the handling of snaplen.
While there fix some whitespace issues. svn path=/trunk/; revision=41164
Diffstat (limited to 'summary.c')
-rw-r--r--summary.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/summary.c b/summary.c
index 0fe058c..d988817 100644
--- a/summary.c
+++ b/summary.c
@@ -166,22 +166,20 @@ summary_fill_in_capture(capture_file *cf,capture_options *capture_opts, summary_
iface.linktype = interface_opts.linktype;
g_array_append_val(st->ifaces, iface);
}
- }else{
- idb_info = wtap_file_get_idb_info(cf->wth);
- for (i = 0; i < idb_info->number_of_interfaces; i++) {
+ } else {
+ idb_info = wtap_file_get_idb_info(cf->wth);
+ for (i = 0; i < idb_info->number_of_interfaces; i++) {
wtapng_if_descr = g_array_index(idb_info->interface_data, wtapng_if_descr_t, i);
iface.cfilter = g_strdup(wtapng_if_descr.if_filter);
iface.name = g_strdup(wtapng_if_descr.if_name);
iface.descr = g_strdup(wtapng_if_descr.if_description);
iface.drops_known = FALSE;
iface.drops = 0;
- /*iface.has_snap = wtapng_if_descr.has_snaplen;*/
iface.snap = wtapng_if_descr.snap_len;
+ iface.has_snap = (iface.snap != 65535);
iface.linktype = wtapng_if_descr.link_type;
g_array_append_val(st->ifaces, iface);
- }
-
-
+ }
}
}
#endif