forked from Imagelibrary/binutils-gdb
Fix seg-fault in readelf when decoding corrupt IA64 unwind information.
PR binutils/18420 * ia64-unwind.c (unw_decode): Add end parameter. Pass parameter on to decode functions. (unw_devode_p2_p5): Pass end paraemter to UNW_DEC_SPILL_MASK. (UNW_DEC_SPILL_MASK): Add end parameter. Check that unw_rlen does not take us beyond the end of the buffer. * ia64-unwind.h (unw_decode): Update prototype. * readelf.c (dump_ia64_unwind): Pass end pointer to unw_decode.
This commit is contained in:
@@ -29,4 +29,4 @@
|
||||
#define UNW_FLAG_UHANDLER(x) ((x) & 0x0000000200000000LL)
|
||||
#define UNW_LENGTH(x) ((x) & 0x00000000ffffffffLL)
|
||||
|
||||
extern const unsigned char *unw_decode (const unsigned char *, int, void *);
|
||||
extern const unsigned char *unw_decode (const unsigned char *, int, void *, const unsigned char *);
|
||||
|
||||
Reference in New Issue
Block a user