Wireshark-dev: Re: [Wireshark-dev] Help with pointer to unions

From: Alex Lindberg <alindber@xxxxxxxxx>
Date: Mon, 18 Apr 2011 19:27:10 -0700 (PDT)
The protocol.  It is a custom protocol used for some of my companies control equipment.

The structure of the protocol packet varies with the release version of the system.  While there are may similarities between versions, the  structures are different enough to have different sizes and makeup etc.

I could create separate dissectors for each version, but that seems like a lot of duplicate effort.  By using an over loaded pointer, the coding would be much easier.  I cannot create different complied version of the protocol, one for each version.

Or is it possible to delay the typing of a variable to runtime?  In that case the type could be control by changing the "version" variable via the preferences during dissector initialization.

As always, thanks for your help.

Alex Lindberg

--- On Mon, 4/18/11, Stephen Fisher <steve@xxxxxxxxxxxxxxxxxx> wrote:

From: Stephen Fisher <steve@xxxxxxxxxxxxxxxxxx>
Subject: Re: [Wireshark-dev] Help with pointer to unions
To: "Developer support list for Wireshark" <wireshark-dev@xxxxxxxxxxxxx>
Date: Monday, April 18, 2011, 11:24 AM

On Mon, Apr 18, 2011 at 09:09:55AM -0700, Alex Lindberg wrote:

> I am working on a dissector that is version dependent.

Dependent on the version of what?  Wireshark or the protocol?
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe