diff options
author | Fernando Nasser <fnasser@redhat.com> | 2000-12-22 15:33:06 +0000 |
---|---|---|
committer | Fernando Nasser <fnasser@redhat.com> | 2000-12-22 15:33:06 +0000 |
commit | a984e6023d090e1d8f1f6f2a7ee63962639e473e (patch) | |
tree | 55269355575c47bb6a97d81c56953547ba160fda | |
parent | ad6da35f893609f6c6300fd55af7bea539262131 (diff) | |
download | gdb-a984e6023d090e1d8f1f6f2a7ee63962639e473e.tar.gz |
2000-12-13 Fernando Nasser <fnasser@redhat.com>
* variables.tcl (constructor): Use the file_changed_hook to remove
all variables if the exec file changes. This prevents the Watch
Window to dump core because the "types" are not valid anymore.
-rw-r--r-- | gdb/gdbtk/library/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/gdbtk/library/variables.tcl | 4 |
2 files changed, 10 insertions, 0 deletions
diff --git a/gdb/gdbtk/library/ChangeLog b/gdb/gdbtk/library/ChangeLog index 7e61109614f..4d06ba0b394 100644 --- a/gdb/gdbtk/library/ChangeLog +++ b/gdb/gdbtk/library/ChangeLog @@ -1,5 +1,11 @@ 2000-12-13 Fernando Nasser <fnasser@redhat.com> + * variables.tcl (constructor): Use the file_changed_hook to remove + all variables if the exec file changes. This prevents the Watch + Window to dump core because the "types" are not valid anymore. + +2000-12-13 Fernando Nasser <fnasser@redhat.com> + * session.tcl (session_save): Save target name. (session_load): Restore target name. diff --git a/gdb/gdbtk/library/variables.tcl b/gdb/gdbtk/library/variables.tcl index c55b41d8e63..76bb253ca49 100644 --- a/gdb/gdbtk/library/variables.tcl +++ b/gdb/gdbtk/library/variables.tcl @@ -39,6 +39,10 @@ class VariableWin { add_hook gdb_no_inferior_hook "$this no_inferior" add_hook gdb_idle_hook [list $this idle] add_hook gdb_clear_file_hook [code $this clear_file] + # FIXME: This is too harsh. We must add to varobj a method + # to re-parse the expressions and compute new types so we can + # keep the contents of the window whenever possible. + add_hook file_changed_hook [code $this clear_file] } # ------------------------------------------------------------------ |