Ethereal-dev: Re: [ethereal-dev] [LEEDSNET] Error output & logginf whilst developing ethereal

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

From: Guy Harris <gharris@xxxxxxxxxxxx>
Date: Fri, 24 Mar 2000 02:47:52 -0800
> I have discovered that if bad values are sent to
>        proto_tree_add_item( )
> in a dissector, a segmentation fault is possible (um, likely) in
>        _proto_tree_add_item_value( )
> in proto.c .
> 
> So, are there any known ways of checking for bad values?

"Bad" in what sense?  Pointer values, for types such as FT_STRING or
FT_BYTES, that are bad pointers?

> Of more relevance to me, is there any harness or infra-structure
> for logging or console output, to track values going into procedures?

No general infrastructure - you can produce console output with
"fprintf(stderr, ...)".