I have a wireshark dissector plugin. I also have a wireshark installed from apt-get. The wireshark loads fine without the plugin inserted in the right place. When I include the plugin .so file and try to run wireshark, I get the following error:
I tried understanding the problem. It says the subtree was already assigned (I'm assuming assigned an ett value) or was not initialized with -1. there are 3 files in my plugin where the API is called and I checked the values of ett[] being supplied to the API in each of these places. They are all initialized to -1. Stuck in a roadblock. Any suggestion would be helpful. Also, I do not understand where wireshark dumps the core. I could not find any core. Any idea about this? asked 03 Dec '13, 08:40 pysudhir edited 03 Dec '13, 08:41 |
One Answer:
...
To which API are you referring? You must not call answered 03 Dec '13, 10:50 Guy Harris ♦♦ That was exactly what I thought. And the error is pretty self explanatory. But, I have checked all the instances of the API register_subtre_array and found that none of the instances are making use of the same ett_ array. (03 Dec '13, 19:18) pysudhir Would it be possible to post your plugin code? (03 Dec '13, 23:31) Kurt Knochner ♦ |
As I indicated at http://stackoverflow.com/questions/20323798/how-to-debug-wireshark-plugin-using-gdb:
You need to first ensure that you can build wireshark and your plugin and that this dev wireshark/plugin load and work.
Based upon your comments, I get the impression that you are building just the plugin and then trying to use it with an installed wireshark. This may work, but it's not the place to start.
I have seen a similar thing happen with an older wireshark. That's the reason I wasn't very worried about the approach. However, I believe that this question is a little different compared to that.