aboutsummaryrefslogtreecommitdiffstats
path: root/summary.c
diff options
context:
space:
mode:
authorguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>1999-10-11 06:39:26 +0000
committerguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>1999-10-11 06:39:26 +0000
commit8abb50f71aa923c7bc87ec4a949dce4374466135 (patch)
treedfec8b639fbd755acc879b925ce7a2d2dd8e9302 /summary.c
parent974baaf856fcec198fa51f03581d03afe39a7f20 (diff)
When a new display filter is to be applied, don't set "cf.dfilter" or
"cf.dfcode" if the new filter doesn't compile, because the filter currently in effect will be the one that was last applied - just free up the text of the new filter, and whatever memory was allocated for the new filter code. This means we allocate a new dfilter when a new filter is to be applied, rather than recycling stuff from the old filter, as we want the old filter code to remain around if the new filter doesn't compile. This means that "cf.dfilter" and "cf.dfcode" will be null if there's no filter in effect. git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@803 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'summary.c')
-rw-r--r--summary.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/summary.c b/summary.c
index 9375ce8bd1..77a0b23162 100644
--- a/summary.c
+++ b/summary.c
@@ -1,7 +1,7 @@
/* summary.c
* Routines for capture file summary window
*
- * $Id: summary.c,v 1.12 1999/09/09 02:42:26 gram Exp $
+ * $Id: summary.c,v 1.13 1999/10/11 06:39:01 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -249,8 +249,8 @@ traffic_bytes/seconds);
add_string_to_box(string_buff, capture_box);
/* Display filter */
- if (DFILTER_CONTAINS_FILTER(cf.dfcode)) {
- snprintf(string_buff, SUM_STR_MAX, "Display filter: %s", cf.dfcode->dftext);
+ if (cf.dfilter) {
+ snprintf(string_buff, SUM_STR_MAX, "Display filter: %s", cf.dfilter);
} else {
sprintf(string_buff, "Display filter: none");
}