diff options
author | Guy Harris <guy@alum.mit.edu> | 2001-01-22 03:33:45 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2001-01-22 03:33:45 +0000 |
commit | 9f2c88966a252520a4bafaa5fee36cf39c1eb85a (patch) | |
tree | d6278fa82b47a9aa4ce9153dbf718e6cfc6b8fdc /packet-hsrp.c | |
parent | 79e1fdb9e56339d8d7e8d9df090dc0386cf4131e (diff) | |
download | wireshark-9f2c88966a252520a4bafaa5fee36cf39c1eb85a.tar.gz wireshark-9f2c88966a252520a4bafaa5fee36cf39c1eb85a.tar.bz2 wireshark-9f2c88966a252520a4bafaa5fee36cf39c1eb85a.zip |
Remove more "CHECK_DISPLAY_AS_DATA()" calls and "pinfo->current_proto ="
statements.
Move the setting of the Protocol column in various dissectors before
anything is fetched from the packet, and also clear the Info column at
that point in those and some other dissectors, so that if an exception
is thrown, the columns don't reflect the previous protocol.
Make the IP dissector static, as it's called only via dissector tables
or dissector handles. Also make the "dissect the TOS field as the
DiffServ DS field" flag static, as it's not referred to outside of
"packet-ip.c".
In the NCP dissector, refer to the port type through "pinfo" rather than
through the global "pi", as it's a tvbuffified dissector.
svn path=/trunk/; revision=2929
Diffstat (limited to 'packet-hsrp.c')
-rw-r--r-- | packet-hsrp.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/packet-hsrp.c b/packet-hsrp.c index ed0b4cbb02..9e6f1cbbd4 100644 --- a/packet-hsrp.c +++ b/packet-hsrp.c @@ -4,7 +4,7 @@ * * Heikki Vatiainen <hessu@cs.tut.fi> * - * $Id: packet-hsrp.c,v 1.15 2001/01/09 06:31:36 guy Exp $ + * $Id: packet-hsrp.c,v 1.16 2001/01/22 03:33:45 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -107,12 +107,10 @@ dissect_hsrp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { guint8 opcode, state; - CHECK_DISPLAY_AS_DATA(proto_hsrp, tvb, pinfo, tree); - - pinfo->current_proto = "HSRP"; - if (check_col(pinfo->fd, COL_PROTOCOL)) col_set_str(pinfo->fd, COL_PROTOCOL, "HSRP"); + if (check_col(pinfo->fd, COL_INFO)) + col_clear(pinfo->fd, COL_INFO); opcode = tvb_get_guint8(tvb, 1); state = tvb_get_guint8(tvb, 2); |