diff options
author | Guy Harris <guy@alum.mit.edu> | 2000-05-31 05:09:07 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2000-05-31 05:09:07 +0000 |
commit | 283ce59938ad2be252a6232e40a958e177a40e1a (patch) | |
tree | b451d4a712d9b914022ba872296e70e55b8d9bc5 /packet-isis-snp.c | |
parent | aa553f63ecc7b9e310a05b743502c50f6dffb800 (diff) | |
download | wireshark-283ce59938ad2be252a6232e40a958e177a40e1a.tar.gz wireshark-283ce59938ad2be252a6232e40a958e177a40e1a.tar.bz2 wireshark-283ce59938ad2be252a6232e40a958e177a40e1a.zip |
Add routines for adding items to a protocol tree that take arguments of
a particular type, rather than taking a varargs list, along the lines of
the "proto_tree_add_XXX_format()" routines.
Replace most calls to "proto_tree_add_item()" and
"proto_tree_add_item_hidden()" with calls to those routines.
Rename "proto_tree_add_item()" and "proto_tree_add_item_hidden()" to
"proto_tree_add_item_old()" and "proto_tree_add_item_hidden_old()", and
add new "proto_tree_add_item()" and "proto_tree_add_item_hidden()"
routines that don't take the item to be added as an argument - instead,
they fetch the argument from the packet whose tvbuff was handed to them,
from the offset handed to them.
svn path=/trunk/; revision=2031
Diffstat (limited to 'packet-isis-snp.c')
-rw-r--r-- | packet-isis-snp.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/packet-isis-snp.c b/packet-isis-snp.c index a5ce886790..da82e77cd9 100644 --- a/packet-isis-snp.c +++ b/packet-isis-snp.c @@ -1,7 +1,7 @@ /* packet-isis-snp.c * Routines for decoding isis complete & partial SNP and their payload * - * $Id: packet-isis-snp.c,v 1.4 2000/05/11 08:15:17 gram Exp $ + * $Id: packet-isis-snp.c,v 1.5 2000/05/31 05:07:14 guy Exp $ * Stuart Stanley <stuarts@mxmail.net> * * Ethereal - Network traffic analyzer @@ -254,9 +254,9 @@ isis_dissect_isis_csnp(int type, int header_length, const u_char *pd, if (tree) { ti = proto_tree_add_item(tree, proto_isis_csnp, NullTVB, - offset, END_OF_FRAME, NULL); + offset, END_OF_FRAME, FALSE); csnp_tree = proto_item_add_subtree(ti, ett_isis_csnp); - proto_tree_add_item(csnp_tree, hf_isis_csnp_pdu_length, NullTVB, + proto_tree_add_uint(csnp_tree, hf_isis_csnp_pdu_length, NullTVB, offset, 2, pntohs(&ilp->isis_csnp_pdu_length)); proto_tree_add_text(csnp_tree, NullTVB, offset + 2, 7, "Source id : %s", @@ -322,9 +322,9 @@ isis_dissect_isis_psnp(int type, int header_length, const u_char *pd, if (tree) { ti = proto_tree_add_item(tree, proto_isis_psnp, NullTVB, - offset, END_OF_FRAME, NULL); + offset, END_OF_FRAME, FALSE); psnp_tree = proto_item_add_subtree(ti, ett_isis_psnp); - proto_tree_add_item(psnp_tree, hf_isis_psnp_pdu_length, NullTVB, + proto_tree_add_uint(psnp_tree, hf_isis_psnp_pdu_length, NullTVB, offset, 2, pntohs(&ilp->isis_psnp_pdu_length)); proto_tree_add_text(psnp_tree, NullTVB, offset + 2, 7, "Source id: %s", |