Skip to content

Commit 0a32cee

Browse files
NothNothNeb
andauthored
FIX: when no fields are returned, create an empty subtree anyway so that search by filter succeeds. (#32)
Closes #31 Co-authored-by: Neb <bgirard@quarkslab.com>
1 parent 4d4ddb5 commit 0a32cee

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

wirego_bridge/dissect.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,10 @@ int dissect_wirego(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da
6363
//How many custom fields did the plugin return?
6464
int result_fields_count = wirego_result_get_fields_count(wirego_h, dissectHandle);
6565

66-
if (result_fields_count <= 0)
66+
if (result_fields_count <= 0) {
67+
proto_tree_add_item(tree, wirego_h->proto_wirego, tvb, 0, -1, ENC_BIG_ENDIAN);
6768
goto DONE;
69+
}
6870

6971
//Add a subtree on this packet
7072
proto_item *ti = proto_tree_add_item(tree, wirego_h->proto_wirego, tvb, 0, -1, ENC_BIG_ENDIAN);

0 commit comments

Comments
 (0)