aboutsummaryrefslogtreecommitdiffstats
path: root/packet-lapb.c
diff options
context:
space:
mode:
authorGilbert Ramirez <gram@alumni.rice.edu>2000-05-11 08:18:09 +0000
committerGilbert Ramirez <gram@alumni.rice.edu>2000-05-11 08:18:09 +0000
commit292e38e2c61edcd14bfa30ca3c72bacda1bcbe32 (patch)
treedb4edef02456a48d0f6d505166ac7d70f6c0f644 /packet-lapb.c
parent162800efb308901e0c302517be01226130e39b19 (diff)
Add tvbuff class.
Add exceptions routines. Convert proto_tree_add_*() routines to require tvbuff_t* argument. Convert all dissectors to pass NULL argument ("NullTVB" macro == NULL) as the tvbuff_t* argument to proto_tree_add_*() routines. dissect_packet() creates a tvbuff_t, wraps the next dissect call in a TRY block, will print "Short Frame" on the proto_tree if a BoundsError exception is caught. The FDDI dissector is converted to use tvbuff's. svn path=/trunk/; revision=1939
Diffstat (limited to 'packet-lapb.c')
-rw-r--r--packet-lapb.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/packet-lapb.c b/packet-lapb.c
index c4e012d764..7ba2899318 100644
--- a/packet-lapb.c
+++ b/packet-lapb.c
@@ -2,7 +2,7 @@
* Routines for lapb frame disassembly
* Olivier Abad <abad@daba.dhis.net>
*
- * $Id: packet-lapb.c,v 1.12 2000/03/15 19:17:08 oabad Exp $
+ * $Id: packet-lapb.c,v 1.13 2000/05/11 08:15:18 gram Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -64,7 +64,7 @@ dissect_lapb(const u_char *pd, frame_data *fd, proto_tree *tree)
if (check_col(fd, COL_INFO))
col_add_str(fd, COL_INFO, "Invalid LAPB frame");
if (tree)
- ti = proto_tree_add_protocol_format(tree, proto_lapb, 0, fd->cap_len,
+ ti = proto_tree_add_protocol_format(tree, proto_lapb, NullTVB, 0, fd->cap_len,
"Invalid LAPB frame");
return;
}
@@ -89,10 +89,10 @@ dissect_lapb(const u_char *pd, frame_data *fd, proto_tree *tree)
is_response = FALSE;
if (tree) {
- ti = proto_tree_add_protocol_format(tree, proto_lapb, 0, 2,
+ ti = proto_tree_add_protocol_format(tree, proto_lapb, NullTVB, 0, 2,
"LAPB");
lapb_tree = proto_item_add_subtree(ti, ett_lapb);
- proto_tree_add_uint_format(lapb_tree, hf_lapb_address, 0, 1, pd[0],
+ proto_tree_add_uint_format(lapb_tree, hf_lapb_address, NullTVB, 0, 1, pd[0],
"Address: 0x%02X", pd[0]);
}
else