> Which leads me to think I made a typo somewhere. Dunno why the code
> ends up in the SNA code, but ok. The ETT_* constants used to create a
> subtree, to what level should these be uniquely used?
The ETT_ constants have nothing to do with which dissector gets called;
they only exist so that, if you open up a particular type of subtree,
the same type of subtree will be opened if you go to another packet.
(Note that opening a particular type of subtree in the *current* packet
doesn't cause all other subtrees of that type to open up in the current
packet. Should we make it do so?)
> Example:
>
> ti = proto_item_add_text( tree, ... );
> subtree = proto_item_add_subtree(ti, ETT_SUBS);
>
> ti2 = proto_item_add_text ( subtree, ... );
> subsubtree = proto_item_add_subtree(ti2, ETT_SUBS);
>
> should this work, or is this blatently stupid?
It'll work, but it means that, if you open up one of those subtrees in
the current packet, if you switch to a different packet, *both* of those
subtrees will be displayed as open.
> Can I use a certain ETT_* constant at any place if I feel like it?
Yes, with the consequences described above.