diff options
author | Guy Harris <guy@alum.mit.edu> | 2002-02-18 01:08:44 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2002-02-18 01:08:44 +0000 |
commit | 6a21dc7e44e06bf3064d74a8e9624b9e01b04bbd (patch) | |
tree | 73281bb2d7e50e8527da2945d5627a31bae9e5c6 /packet-clnp.c | |
parent | d92a1cd8e1f58a1ec46793f9052aa893a279e523 (diff) |
Don't give tvbuffs names; instead, give data sources names, where a
"data source" has a name and a top-level tvbuff, and frames can have a
list of data sources associated with them.
Use the tvbuff pointer to determine which data source is the data source
for a given field; this means we don't have to worry about multiple data
sources with the same name - the only thing the name does is label the
notebook tab for the display of the data source, and label the hex dump
of the data source in print/Tethereal output.
Clean up a bunch of things discovered in the process of doing the above.
svn path=/trunk/; revision=4749
Diffstat (limited to 'packet-clnp.c')
-rw-r--r-- | packet-clnp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packet-clnp.c b/packet-clnp.c index 491a75f301..0671464552 100644 --- a/packet-clnp.c +++ b/packet-clnp.c @@ -1,7 +1,7 @@ /* packet-clnp.c * Routines for ISO/OSI network and transport protocol packet disassembly * - * $Id: packet-clnp.c,v 1.48 2002/01/30 22:58:54 guy Exp $ + * $Id: packet-clnp.c,v 1.49 2002/02/18 01:08:35 guy Exp $ * Laurent Deniel <deniel@worldnet.fr> * Ralf Schneider <Ralf.Schneider@t-online.de> * @@ -1902,7 +1902,7 @@ static void dissect_clnp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) /* Allocate a new tvbuff, referring to the reassembled payload. */ next_tvb = tvb_new_real_data(fd_head->data, fd_head->datalen, - fd_head->datalen, "Reassembled"); + fd_head->datalen); /* Add the tvbuff to the list of tvbuffs to which the tvbuff we were handed refers, so it'll get cleaned up when that tvbuff @@ -1910,7 +1910,7 @@ static void dissect_clnp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) tvb_set_child_real_data_tvbuff(tvb, next_tvb); /* Add the defragmented data to the data source list. */ - pinfo->fd->data_src = g_slist_append(pinfo->fd->data_src, next_tvb); + add_new_data_source(pinfo->fd, next_tvb, "Reassembled"); /* It's not fragmented. */ pinfo->fragmented = FALSE; |