GElf_Rela *rela_mem, struct where *where,
enum skip_type st)
{
- if (reloc == NULL)
+ if (reloc == NULL || reloc->data == NULL)
return NULL;
while (reloc->index < reloc->count)
relocation_skip (struct relocation_data *reloc, uint64_t offset,
struct where *where, enum skip_type st)
{
+ if (reloc == NULL || reloc->data == NULL)
+ return;
+
GElf_Rela rela_mem;
relocation_next (reloc, offset - 1, &rela_mem, where, st);
}
static void
relocation_skip_rest (struct relocation_data *reloc, enum section_id sec)
{
+ if (reloc == NULL || reloc->data == NULL)
+ return;
+
GElf_Rela rela_mem;
relocation_next (reloc, (uint64_t)-1, &rela_mem,
&WHERE (sec, NULL), skip_mismatched);