From 42e00655522d8338f012f7da388d058d5d9cf7e2 Mon Sep 17 00:00:00 2001 From: Ronnie Sahlberg Date: Fri, 1 Nov 2002 01:11:59 +0000 Subject: Fix for small bug that crashed tethereal if a tap filter was applied and tethereal forgot to tell epan_dissect_new() to build a tree svn path=/trunk/; revision=6529 --- tethereal.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tethereal.c') diff --git a/tethereal.c b/tethereal.c index bcab936b21..e307576bc8 100644 --- a/tethereal.c +++ b/tethereal.c @@ -1,6 +1,6 @@ /* tethereal.c * - * $Id: tethereal.c,v 1.167 2002/10/31 22:16:01 guy Exp $ + * $Id: tethereal.c,v 1.168 2002/11/01 01:11:59 sahlberg Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs @@ -1684,7 +1684,7 @@ wtap_dispatch_cb_print(guchar *user, const struct wtap_pkthdr *phdr, fill_in_fdata(&fdata, cf, phdr, offset); passed = TRUE; - if (cf->rfcode || verbose) + if (cf->rfcode || verbose || num_tap_filters!=0) create_proto_tree = TRUE; else create_proto_tree = FALSE; @@ -1693,6 +1693,7 @@ wtap_dispatch_cb_print(guchar *user, const struct wtap_pkthdr *phdr, We only need the columns if we're *not* verbose; in verbose mode, we print the protocol tree, not the protocol summary. */ + edt = epan_dissect_new(create_proto_tree, verbose); if (cf->rfcode) { epan_dissect_prime_dfilter(edt, cf->rfcode); -- cgit v1.2.3