Segfault in ~raw2trace_t when modfule file is not parsed correctly
Created by: Carrotman42
raw2trace_t.modhandle is only initialized in raw2trace_t::read_and_map_modules when drmodtrack_offline_read returns successfully, otherwise it is left untouched. In the scenario where drmodtrack_offline_read returns an error, the destructor of raw2trace_t calls raw2trace_t::unmap_modules which calls drmodtrack_offline_exit, passing the uninitialized modhandle pointer to it. This causes a segfault when drmodtrack_offline_exit tries to dereference the pointer.
I have a simple fix for this, just submitting an issue for tracking purposes.