Wireshark mailing list archives
Re: Modbus/TCP hookup for subdissector
From: Chris Maynard <chris.maynard () gtech com>
Date: Fri, 25 Mar 2011 16:05:42 +0000 (UTC)
Roland Knall <rknall@...> writes:
1. Is there a way to provide additional information to the subdissector? Someone could use private_data, but that field I need somewhere else, therefore can not be used here.
I haven't looked at the patch or anything, but I just wanted to comment on this part. If you want/need to use the private data, you can do what several dissectors do and save a pointer to the current private_data before replacing the pinfo->private_data with your own, then restore the original afterwards. One example is packet-http.c, but there are others. (search for "save_private_data") ___________________________________________________________________________ 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:
- Modbus/TCP hookup for subdissector Roland Knall (Mar 25)
- Re: Modbus/TCP hookup for subdissector Chris Maynard (Mar 25)
- Re: Modbus/TCP hookup for subdissector Roland Knall (Mar 25)
- Re: Modbus/TCP hookup for subdissector Anders Broman (Mar 25)
- Re: Modbus/TCP hookup for subdissector Roland Knall (Mar 25)
- Re: Modbus/TCP hookup for subdissector Chris Maynard (Mar 25)