Hi all,
I have now an UAT dialog. In the ~~copy_cb of the records, I am allocating an object and passing it to a registry that I maintain in the dissector.
The registry is initialized like this:
registry = wmem_map_new_autoreset(wmem_epan_scope(), wmem_file_scope(), hash_by_guid, compare_by_guid);
However, if there is already an object in the UAT config file, when I start Wireshark (I know that we are out of the file scope) I get the following error:
ERROR:wmem_core.c:52:wmem_alloc: assertion failed: (allocator->in_scope)
Aborted (core dumped)
Because I am doing:
type_mapping_object = wmem_new(wmem_file_scope(), type_mapping);
My question is, how can I manage this situation? should I allocate the object in a different callback? or should I change the scope? I have tried wmem_epan_scope() and it doesn't work either.
My goal is to populate the registry with the information I have in the UAT configuration file.
Thanks,
Juanjo Martin