Ethereal-dev: AW: AW: [Ethereal-dev] Plugin naming conventions?

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

From: "Grossert, Alexander" <Alexander.Grossert@xxxxxxxxxxx>
Date: Fri, 17 Mar 2006 14:03:06 +0100
Sure. It was just there because the plugin_register is of course only called, when the code is compiled as a dll. In case of a built-in dissector the test proto_register_xxx is called directly.

By the way....PROBLEM SOLVED!

I rebuilt the dev sources of ethereal completely and added the plugin there, instead of the standard distribution. When I started it, a so called "debug console" popped up to tell me that the protocol filter name (it is described by parameter abbreviation in funtion proto_register_protocol) contained "illegal" characters. In my case it was just a capital character.

Well, who would expect a capital letter in the protocol abbreviation to crash the registration of the register process?

Does someone have an idea why it has been implemented that way and why registering chrashes due to this character?



-----Ursprüngliche Nachricht-----
Von: ethereal-dev-bounces@xxxxxxxxxxxx [mailto:ethereal-dev-bounces@xxxxxxxxxxxx] Im Auftrag von Jaap Keuter
Gesendet: Freitag, 17. März 2006 12:34
An: Ethereal development
Betreff: Re: AW: [Ethereal-dev] Plugin naming conventions?

Hi,

The 'if (proto_p60 == -1)' check doesn't have to be done here since you
did that in the plugin_register(), right?

Thanx,
Jaap


On Fri, 17 Mar 2006, Grossert, Alexander wrote:

> I tested it with the Visual C++ debugger.
>
> I took a look at the call stack and the position where it crashed. This was the result:
>
> The chrash happens in function prefs_register_module_or_subtree() and seems to be created by this call:
>
> p60_module = prefs_register_protocol(proto_p60, proto_reg_handoff_p60);
>
> The whole register function looks like this:
>
> void proto_register_p60(void){
>
> 	module_t *p60_module;
> 	if (proto_p60 == -1) {
> 		proto_p60 = proto_register_protocol (
> 							"P600", /* name */
> 							"P600", /* short name */
> 							"P600" /* abbrev */);
> 	}
> 	p60_module = prefs_register_protocol(proto_p60, proto_reg_handoff_p60);
> }
>
> It is exactly the same code as for the foo protocol, except for the replacements of foo by p60.
> This is why I cannot understand what the problem might be.
>
>
> -----Ursprüngliche Nachricht-----
> Von: ethereal-dev-bounces@xxxxxxxxxxxx [mailto:ethereal-dev-bounces@xxxxxxxxxxxx] Im Auftrag von LEGO
> Gesendet: Freitag, 17. März 2006 11:23
> An: Ethereal development
> Betreff: Re: [Ethereal-dev] Plugin naming conventions?
>
> Try to run it under a debugger and see where it crashes.
>
> On 3/17/06, Grossert, Alexander <Alexander.Grossert@xxxxxxxxxxx> wrote:
> >
> >
> > Hello.
> >
> > After going through the foo-tutorial of plugin development successfully I
> > started creating my own plugin based on the functioning sources of foo.dll
> >
> > My protocol was named p600. I just renamed all resources of the tutorial and
> > built it all over again. Afterwards I copied the new dll to the plugin
> > folder of the standard win32 distribution of ethereal and expected it to
> > start normally...well it did not!
> >
> > I only get two message boxes telling me:
> >
> >         Unspecified fatal error encountered, aborting.
> >
> > and
> >
> >         Runtime Error!
> >
> >         Program:C:\Program Files\Ethereal\ethereal.exe
> >
> >         This application has requested the Runtime to terminate it in an
> > unusual way.
> >         Please contact the application's support team for more information.
> >
> > I also tried replacing the zeros with Os, putting something before p6, and
> > so on.
> >
> > Anyone an idea, why ethereal crashes?
> > _______________________________________________
> > Ethereal-dev mailing list
> > Ethereal-dev@xxxxxxxxxxxx
> > http://www.ethereal.com/mailman/listinfo/ethereal-dev
> >
> >
> >
>
>
> --
> oggi banane domani mortadella
> _______________________________________________
> Ethereal-dev mailing list
> Ethereal-dev@xxxxxxxxxxxx
> http://www.ethereal.com/mailman/listinfo/ethereal-dev
> _______________________________________________
> Ethereal-dev mailing list
> Ethereal-dev@xxxxxxxxxxxx
> http://www.ethereal.com/mailman/listinfo/ethereal-dev
>
>

_______________________________________________
Ethereal-dev mailing list
Ethereal-dev@xxxxxxxxxxxx
http://www.ethereal.com/mailman/listinfo/ethereal-dev