Wireshark-dev: Re: [Wireshark-dev] Disabling a dissector doesn't seem to quite work.
From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Sun, 16 Sep 2012 13:39:41 -0700
On Sep 16, 2012, at 12:49 AM, Joerg Mayer <jmayer@xxxxxxxxx> wrote:

> On Sat, Sep 15, 2012 at 03:44:59PM -0700, Guy Harris wrote:
>>> My understanding of dissectors registering to port 0 was simply a method for
>>> allowing "Decode As" to work.
>> 
>> The right way for a dissector to say "I run atop {TCP,UDP,...} but I don't have a standard port number, so use "Decode As..."" is to call dissector_add() with a dissector handle and a dissector table name.
> 
> As dissector_add happens to be a) used nowhere and b) #defined to dissector_add_uint,
> that may have been the case but is definitely not what today's code looks like.

Sorry, I meant "dissector_add_handle()", not "dissector_add()".

> If there's no opposition, I will remove that #define.

We might as well, unless

	1) there's a way (at least with GCC-compatible compilers) to deprecate a macro (as opposed to a function)

and

	2) we want to deprecate the old APIs for one release before removing it.