Wireshark-dev: Re: [Wireshark-dev] was: Adding Files to Wireshark (new developer)
From: Bill Meier <wmeier@xxxxxxxxxxx>
Date: Fri, 01 Apr 2011 14:36:50 -0400
On 4/1/2011 12:57 PM, Chaswi Przellczyk wrote:

Dear Stephen,

that would be a good way to get this solved. I went ahead and
modified packet-rtp.c to add a field for a sampling-rate preference.
That works nice. BUT the preferences are typically used in the
dissectors, which is not true for my case. I can make the variable
visible in all files (make it truly global), but I'm wondering if
that's the right way to go. At the very least it would differ from
what I've seen in other source-files. Is there a different way of
accessing these preferences "correctly"?



Take at look at the data struct passed to register_tap() (or whatever
it's called) when the tap is created by the dissector.

I'm not a 'tap' expert, but I think a ptr to that struct is passed to
the tap callback fcn called for each frame.

Also  see doc/README.tapping