+2020-08-26 Alan Modra <amodra@gmail.com>
+
+ PR 26507
+ * elf32-xtensa.c (find_removed_literal): Don't bsearch empty map.
+
2020-08-26 Alan Modra <amodra@gmail.com>
PR 26506
if (removed_list->map == NULL)
map_removed_literal (removed_list);
- p = bsearch (&addr, removed_list->map, removed_list->n_map,
- sizeof (*removed_list->map), removed_literal_compare);
- if (p)
+ if (removed_list->map != NULL)
{
- while (p != removed_list->map && (p - 1)->addr == addr)
- --p;
- r = p->literal;
+ p = bsearch (&addr, removed_list->map, removed_list->n_map,
+ sizeof (*removed_list->map), removed_literal_compare);
+ if (p)
+ {
+ while (p != removed_list->map && (p - 1)->addr == addr)
+ --p;
+ r = p->literal;
+ }
}
return r;
}