This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Avoid potential crashes with --gc-sections and low addresses


Jonathan Larmour wrote:
> Hi,
> 
> The attached patch deals with a problem that occurs with some embedded
> targets when the linker garbage collection feature of GNU ld
> (--gc-sections) is used.

<ahem> and the patch is now attached.

Jifl
-- 
eCosCentric Limited      http://www.eCosCentric.com/     The eCos experts
Barnwell House, Barnwell Drive, Cambridge, UK.       Tel: +44 1223 245571
Registered in England and Wales: Reg No 4422071.
------["Si fractum non sit, noli id reficere"]------       Opinions==mine
--- gdb/dwarf2-frame.c~	2008-05-04 00:24:17.000000000 +0100
+++ gdb/dwarf2-frame.c	2008-06-20 17:06:04.000000000 +0100
@@ -1795,7 +1795,8 @@ decode_frame_entry_1 (struct comp_unit *
 
       fde->eh_frame_p = eh_frame_p;
 
-      add_fde (unit, fde);
+      if (fde->initial_location)
+          add_fde (unit, fde);
     }
 
   return end;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]