Wireshark mailing list archives
Reverting proto_tree_reset()
From: Jakub Zawadzki <darkjames-ws () darkjames pl>
Date: Wed, 31 Oct 2012 11:42:31 +0100
Hi, in r45669 I added two new functions: epan_dissect_reset, proto_tree_reset. In BTS we have got bug #2047[1] which is something simillar, but: 1/ IMHO it has minimal impact for speed, and this functions duplicates some code. 2/ major thing for me was to make referencing (HF_REF_TYPE_DIRECT), and unreferencing (HF_REF_TYPE_NONE) hfinfo->ref_type multi-thread dissection safe. But achieving #2 can be done with some simpler code, rename dfilter_prime_proto_tree to dfilter_prime() + remove tree argument, and use new function after compiling dfilter and *before* dissection loops. Create new function dfilter_unprime() which unreference hfs, and call this funcion *after* dissection loop. last point, r45669 is buggy, it never set hfi->ref_type back to HF_REF_TYPE_NONE. So, I'll probably revert r45669, and fix it like I described above, I can prepare patch if anyone want to do review? Dunno what to do with bug #2047 WONTFIX? Anders? [1] https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2047 ___________________________________________________________________________ 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:
- Reverting proto_tree_reset() Jakub Zawadzki (Oct 31)
- Re: Reverting proto_tree_reset() Anders Broman (Oct 31)
- Re: Reverting proto_tree_reset() Jakub Zawadzki (Oct 31)
- Re: Reverting proto_tree_reset() Anders Broman (Oct 31)
- Re: Reverting proto_tree_reset() Jakub Zawadzki (Oct 31)
- Re: Reverting proto_tree_reset() Anders Broman (Oct 31)