Wireshark mailing list archives
Re: Proper private_data usage
From: Jeff Morriss <jeff.morriss.ws () gmail com>
Date: Tue, 15 Oct 2013 17:29:37 -0400
On 10/15/13 13:11, Christopher Maynard wrote:
Jeff Morriss <jeff.morriss.ws@...> writes:But, yes, I think that when using private_data the restoration is necessary: otherwise if you have multiple PDUs in one frame then an exception in one of the early PDUs will cause the private_data to be wrong when the next PDU is dissected. This is one of the reasons not to use private_data at all.Would it be safer and easier to maintain if this was instead done within call_dissector() and friends?
Probably but I've always had this belief that TRY/CATCH stuff was expensive so I try not to put them in (and have, in several cases, taken them out when they were clearly not necessary). Unfortunately I don't remember why I think they are expensive...
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- Proper private_data usage Christopher Maynard (Oct 15)
- Re: Proper private_data usage Jeff Morriss (Oct 15)
- Re: Proper private_data usage Christopher Maynard (Oct 15)
- Re: Proper private_data usage Jeff Morriss (Oct 15)
- Re: Proper private_data usage Christopher Maynard (Oct 15)
- Re: Proper private_data usage Jeff Morriss (Oct 15)