This is the mail archive of the gdb-patches@sources.redhat.com 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: [RFA] breakpoints.c clear_command fix


On Friday 05 April 2002 05:55 pm, Michael Snyder wrote:
> "Martin M. Hunt" wrote:
> > The clear command improperly detects overlays and fails
> > to clear breakpoints if overlays are not disabled.
> >
> > Tested with linux-x-mips (overlays enabled) and linux x86 native.
>
> Martin, you really made me think with this one.  Sorry it took so long.
> I had to go back eleven years in the code base to understand what this
> code was trying to do -- which made me realize that it's painfully
> obsolete.  It has two inner loops with identical control conditions
> (except that they've gotten out of sync), just because they didn't
> have ALL_BREAKPOINTS_SAFE when this code was written.

I was wondering why the two seperate loops.  I didn't understand the comments 
so I made the minimum changes that seemed logical.

> So I rewrote the whole damn function.   ;-)

Great!

It looks fine and it passes all my test cases.  Thanks.

-- 
Martin Hunt
GDB Engineer
Red Hat, Inc.


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