From bf043a5f9c9f807d670276b6c389bf5439245edb Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Tue, 20 Oct 2009 13:55:15 +0200 Subject: Be paranoid about table size resolving cie_for_fde and fde_pointer_type. * runtime/unwind.c (cie_for_fde): Take table and table_len into account. (fde_pointer_type): Likewise. * runtime/unwind/unwind.h: Adjust function prototypes. --- runtime/unwind/unwind.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'runtime/unwind/unwind.h') diff --git a/runtime/unwind/unwind.h b/runtime/unwind/unwind.h index 285a3a34..023ea603 100644 --- a/runtime/unwind/unwind.h +++ b/runtime/unwind/unwind.h @@ -143,8 +143,10 @@ static unsigned long read_pointer(const u8 **pLoc, const void *end, signed ptrType); static const u32 bad_cie, not_fde; -static const u32 *cie_for_fde(const u32 *fde, void *table, int is_ehframe); -static signed fde_pointer_type(const u32 *cie); +static const u32 *cie_for_fde(const u32 *fde, void *table, + uint32_t table_len, int is_ehframe); +static signed fde_pointer_type(const u32 *cie, + void *table, uint32_t table_len); #endif /* STP_USE_DWARF_UNWINDER */ -- cgit