mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2025-12-31 20:36:25 +00:00
libsysprof-analyze: check if ELF matches inode/build-id
We still want to load it into the cache as it could get used by other symbols/mmap regions, but don't return the ELF if it won't match an inode or build-id check. Rely on other fallbacks to create fallback symbols for those use cases.
This commit is contained in:
@ -69,7 +69,8 @@ main (int argc,
|
||||
g_autoptr(SysprofDocumentMmap) memory_map = g_list_model_get_item (memory_maps, j);
|
||||
const char *file = sysprof_document_mmap_get_file (memory_map);
|
||||
const char *build_id = sysprof_document_mmap_get_build_id (memory_map);
|
||||
g_autoptr(SysprofElf) elf = sysprof_elf_loader_load (elf_loader, info->mount_namespace, file, build_id, &error);
|
||||
guint64 file_inode = sysprof_document_mmap_get_file_inode (memory_map);
|
||||
g_autoptr(SysprofElf) elf = sysprof_elf_loader_load (elf_loader, info->mount_namespace, file, build_id, file_inode, &error);
|
||||
|
||||
if (elf == NULL)
|
||||
g_print ("%u: %s [unresolved]\n", info->pid, file);
|
||||
|
||||
Reference in New Issue
Block a user