This is the mail archive of the gdb-prs@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]

[Bug breakpoints/11368] New: breakpoint deleted twice when using call command that loads shared object


I hacked this out. 
1. The call (print) command. Sets up a cleanup marker to clean everything
(including breakpoints) during the call command execution. Some breakpoints are
generated (gdb internal). 
2. Then the called function  loads a shared object. At this point gdb gets a
load shared object event. gdb then decides to reset all breakpoints.
3. The reset breakpoint function deletes all breakpoints and their dynamic
memory. HOWEVER it does so bypassing the intended cleanup mecahnism in gdb which
utilizes cleanup lists.
4. Thus a situation happens where the cleanup list entries point to already
deleted locations.
5. When the called function exits the control is returned to the gdb call
command. The command finalizes with a cleanup using the cleanup lists and tries
to free already free'ed memory - and hits an exception.

-- 
           Summary: breakpoint deleted twice when using call command that
                    loads shared object
           Product: gdb
           Version: 7.0
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: breakpoints
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: danny dot geist at gmail dot com
                CC: gdb-prs at sourceware dot org
GCC target triplet: i686-pc-linux-gnu


http://sourceware.org/bugzilla/show_bug.cgi?id=11368

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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