Bug 24722 - deleting a breakpoint does not make the "b" disappear
Summary: deleting a breakpoint does not make the "b" disappear
Status: RESOLVED FIXED
Alias: None
Product: gdb
Classification: Unclassified
Component: tui (show other bugs)
Version: HEAD
: P2 normal
Target Milestone: 9.1
Assignee: Tom Tromey
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-06-22 17:34 UTC by Tom Tromey
Modified: 2019-11-13 07:22 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Tromey 2019-06-22 17:34:51 UTC
Enter the TUI.  Make a breakpoint somewhere in the visible
source code, and notice that a "b" appears in the margin.
Now, "delete" the breakpoint -- the "b" remains.
Comment 1 Tom Tromey 2019-06-24 03:25:42 UTC
I have a patch.
Comment 2 Sourceware Commits 2019-07-17 18:37:23 UTC
The master branch has been updated by Tom Tromey <tromey@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=0807ab7b88fa5ffb138ba1ee22b33d26e239de2f

commit 0807ab7b88fa5ffb138ba1ee22b33d26e239de2f
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Jun 23 21:25:46 2019 -0600

    Remove deleted breakpoint from TUI display
    
    PR tui/24722 points out that deleting a breakpoint does not cause the
    "b" to be removed from the breakpoint display.  The issue here was
    that the breakpoint still exists at the moment the breakpoint-deleted
    observer is notified.  This fixes the problem by specially handling
    the case where a breakpoint is being removed.
    
    gdb/ChangeLog
    2019-07-17  Tom Tromey  <tom@tromey.com>
    
    	PR tui/24722:
    	* tui/tui-winsource.h (tui_update_all_breakpoint_info)
    	(tui_update_breakpoint_info): Add "being_deleted" parameter.
    	* tui/tui-winsource.c (tui_update_source_window_as_is): Update.
    	(tui_update_all_breakpoint_info): Add "being_deleted" parameter.
    	(tui_update_breakpoint_info): Likewise.
    	* tui/tui-hooks.c (tui_event_create_breakpoint)
    	(tui_event_delete_breakpoint, tui_event_modify_breakpoint):
    	Update.
Comment 3 Tom Tromey 2019-07-17 18:42:35 UTC
It turns out that patch is not sufficient :(
so I am leaving this open.
Comment 4 Tom Tromey 2019-11-13 07:22:21 UTC
I tried this today and it works, so I'm closing this now.