aboutsummaryrefslogtreecommitdiffstats
path: root/dfilter.c
diff options
context:
space:
mode:
authorGilbert Ramirez <gram@alumni.rice.edu>2000-09-13 20:30:48 +0000
committerGilbert Ramirez <gram@alumni.rice.edu>2000-09-13 20:30:48 +0000
commit2825d16166d27e8c40ce355ac186e9e4551bee35 (patch)
tree966ac85d174c71209d552423cab98175b252f8f1 /dfilter.c
parent89cfd643ffa43560a12eb1ccfb19440f25386a64 (diff)
Don't put hf_text_only into the tree of filter-able protocols and fields.
svn path=/trunk/; revision=2429
Diffstat (limited to 'dfilter.c')
-rw-r--r--dfilter.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/dfilter.c b/dfilter.c
index ec163e6e64..24266bc13d 100644
--- a/dfilter.c
+++ b/dfilter.c
@@ -1,7 +1,7 @@
/* dfilter.c
* Routines for display filters
*
- * $Id: dfilter.c,v 1.37 2000/08/11 13:35:31 deniel Exp $
+ * $Id: dfilter.c,v 1.38 2000/09/13 20:30:48 gram Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -80,6 +80,8 @@ static void clear_byte_array(gpointer data, gpointer user_data);
*/
#define g_array_index_ptr(a,s,i) (((guint8*) (a)->data) + (i*s))
+extern int hf_text_only; /* in proto.c */
+
void
dfilter_init(void)
{
@@ -90,7 +92,11 @@ dfilter_init(void)
/* Add the header field and protocol abbrevs to the symbol table */
num_symbols = proto_registrar_n();
+
for (i=0; i < num_symbols; i++) {
+ if (i == hf_text_only) {
+ continue;
+ }
s = proto_registrar_get_abbrev(i);
g_assert(s); /* Not Null */
g_assert(s[0] != 0); /* Not empty string */
@@ -99,7 +105,6 @@ dfilter_init(void)
g_message("Already have abbreviation \"%s\"", s);
g_assert(0);
}
- /*g_message("Adding %s", s);*/
symbol = DFILTER_LEX_ABBREV_OFFSET + i;
g_tree_insert(dfilter_tokens, s, GINT_TO_POINTER(symbol));
}