diff options
author | Peter Schauer <Peter.Schauer@mytum.de> | 1994-09-10 08:50:10 +0000 |
---|---|---|
committer | Peter Schauer <Peter.Schauer@mytum.de> | 1994-09-10 08:50:10 +0000 |
commit | 26a859ec838aa00054f5504cbe3dc2e09771ed81 (patch) | |
tree | b8f9c559018ce1afc32d332cb4d0aa582d0682de /gdb/values.c | |
parent | b35be5109247d25244c3ee581c83fd01b86e0b93 (diff) | |
download | binutils-gdb-26a859ec838aa00054f5504cbe3dc2e09771ed81.tar.gz |
* corelow.c (add_solib_stub): Copy to_sections changes from
core_ops to current_target after adding the shared libraries.
* partial-stab.h (N_EXCL), dbxread.c (add_old_header_file,
find_corresponding_bincl_psymtab): Change `repeated header not seen'
error to a complaint, simplify complaint.
* procfs.c (signalname, errnoname): Make `name' const.
* symfile.c (reread_symbols): Use filename from old BFD to
reopen the objfile.
* values.c (record_latest_value): Don't record value in the
history chain until we are sure there won't be an error.
Diffstat (limited to 'gdb/values.c')
-rw-r--r-- | gdb/values.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gdb/values.c b/gdb/values.c index 1c833af52c8..1eaef33254b 100644 --- a/gdb/values.c +++ b/gdb/values.c @@ -259,6 +259,18 @@ record_latest_value (val) if (i) return -1; /* Indicate value not saved in history */ } + /* We don't want this value to have anything to do with the inferior anymore. + In particular, "set $1 = 50" should not affect the variable from which + the value was taken, and fast watchpoints should be able to assume that + a value on the value history never changes. */ + if (VALUE_LAZY (val)) + value_fetch_lazy (val); + /* We preserve VALUE_LVAL so that the user can find out where it was fetched + from. This is a bit dubious, because then *&$1 does not just return $1 + but the current contents of that location. c'est la vie... */ + val->modifiable = 0; + release_value (val); + /* Here we treat value_history_count as origin-zero and applying to the value being stored now. */ @@ -275,18 +287,6 @@ record_latest_value (val) value_history_chain->values[i] = val; - /* We don't want this value to have anything to do with the inferior anymore. - In particular, "set $1 = 50" should not affect the variable from which - the value was taken, and fast watchpoints should be able to assume that - a value on the value history never changes. */ - if (VALUE_LAZY (val)) - value_fetch_lazy (val); - /* We preserve VALUE_LVAL so that the user can find out where it was fetched - from. This is a bit dubious, because then *&$1 does not just return $1 - but the current contents of that location. c'est la vie... */ - val->modifiable = 0; - release_value (val); - /* Now we regard value_history_count as origin-one and applying to the value just stored. */ |