Ethereal-users: Re: [Ethereal-users] Effort to implement support for a new protocol

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

From: Andy Howell <AndyHowell@xxxxxxxxxxxxx>
Date: Mon, 28 Jul 2003 21:17:47 -0500
Guy Harris wrote:

On Monday, July 28, 2003, at 3:31 PM, Andy Howell wrote:

    Setting column headings is done before if(tree)


Not necessarily. It has to be done regardless of whether the "tree" argument is null, but you can set column headings after you start building the protocol tree.


I think I was doing something phenomenally stupid like:

if (check_col(pinfo->cinfo, COL_INFO))
	build_my_info_str(..., col_info);
	col_add_str(pinfo->cinfo, COL_INFO, col_info);

It kept coring 'cause cinfo was null. It was only later after I moved the COL_INFO stuff before the if(tree) that I noticed the lack of brackets on my "if". Arrgg.

Yes - when you click on a frame the keyboard and/or mouse is grabbed (I forget which). At home, at least, I use a version of GTK+ that I hacked to have a "--gtk-no-grabs" command-line argument, which disables those grabs, and run Ethereal with that argument when debugging.

Hmm, that sounds like a neat trick. Is it only the GTK+ lib that needs hacking?

On another note, is there a way to speed up the build? After compiling, ethereal seems to be a script that then does further linking. To debug, I have to run it once, exit, and run .libs/lt-ethereal to run it under the debugger. Is there a faster way? I tried to get it to build a static version, but ran into problems. The 2am "I'll just try it one more time..." kind of problems that I don't really remember what they were.

I was tempted to rip out all the dissectors I don't need to speed up the whole process. I'm working with a UDP based protocol, so that is all I need. If I just have Frame, Ethernet II, IP and UDP will it work?

Thanks,

	Andy