ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
April 17th, 2024 | 14:30-16:00 SGT (UTC+8) | Online

Wireshark-dev: Re: [Wireshark-dev] pinfo->private_data usage

From: yin sun <sunyin51@xxxxxxxxx>
Date: Thu, 25 Jun 2009 21:52:32 -0600
Isn't it depend on the agreement between caller that setup the data and the called dissector that uses the data.
If the caller wants to enforce it, that is fine. But I don't see a general rule here. What if the case that sub-dissector wants to pass back some value. private_data is also the only way to do so.

/Yin

On Thu, Apr 23, 2009 at 5:51 AM, Tamazov, Artem <artem.tamazov@xxxxxxxxxxx> wrote:
Hello,
 
Am I correct that it is OK to use pinfo->private_data to pass information to sub-dissectors?
Should dissector save pinfo->private_data and restore it after calling all sub-dissectors it needs?
 
I've seen plenty of dissectors which do not follow this rule and going to fix them.
To Wireshark core developers: your opinion?
 
Most cases are trivial, except automatically generated files (which I should not modify
and count on ASN.1 compiler, for example) *and* packet-rpc.c written by Uwe Girlich.
Any ideas about packet-rpc?
 
Regards,
ATA /*Artem Tamazov*/
 
============================================================
The information contained in this message may be privileged
and confidential and protected from disclosure. If the reader
of this message is not the intended recipient, or an employee
or agent responsible for delivering this message to the
intended recipient, you are hereby notified that any reproduction,
dissemination or distribution of this communication is strictly
prohibited. If you have received this communication in error,
please notify us immediately by replying to the message and
deleting it from your computer. Thank you. Tellabs
============================================================

___________________________________________________________________________
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