Ethereal-dev: Re: [Ethereal-dev] Latest Ethereal profiling data ...

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: didier <dgautheron@xxxxxxxx>
Date: Tue, 02 Dec 2003 20:42:07 +0000
Guy Harris wrote:
On Mon, Dec 01, 2003 at 05:43:46PM +0000, didier wrote:

BTW, why do we use a pointer for value in field_info (proto.h) and in
proto_node?
         fvalue_t                        *value;
} field_info;


Probably because that was the most straightforward way to deal with
objects of a particular type.

"fvalue_t" is defined in "epan/ftypes/ftypes.h", so the structure is
exported; we could probably have an "fvalue_init()" routine that took a
pointer to an "fvalue_t" and an "ftenum_t" as arguments and initialized
the "fvalue_t" appropriately for that type, and an FVALUE_CLEANUP macro
that calls the free routine for the value if it exists, and include the
"fvalue_t" in the field_info structure.
Attached a patch for field_info  fvalue_t *value to fvalue_t fvalue

Didier

Attachment: ethereal.gz
Description: Unix tar archive