mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-26 17:18:55 +00:00
More fixes for memory access errors when running readelf on fuzzed binaries.
PR binutils/17531 * dwarf.c (process_debug_info): Check for abbrev_base being larger than the section size. (process_cu_tu_index): Use xcalloc2 to allocate the CU and TU arrays. (xcalloc2): New function. Like xcalloc, but checks for overflow. * dwarf.h (xcalloc2): Prototype.
This commit is contained in:
@@ -251,6 +251,7 @@ extern void dwarf_select_sections_all (void);
|
||||
extern unsigned int * find_cu_tu_set (void *, unsigned int);
|
||||
|
||||
extern void * cmalloc (size_t, size_t);
|
||||
extern void * xcalloc2 (size_t, size_t);
|
||||
extern void * xcmalloc (size_t, size_t);
|
||||
extern void * xcrealloc (void *, size_t, size_t);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user