diff options
author | Doug Evans <xdje42@gmail.com> | 2014-12-12 23:25:46 -0800 |
---|---|---|
committer | Doug Evans <xdje42@gmail.com> | 2014-12-12 23:25:46 -0800 |
commit | ae6a105d22fb603dbfb956bbcedf9ae469323d55 (patch) | |
tree | 66e9b8be45244d096bbfdbb4314951f82fb2154d /gdb/valops.c | |
parent | 59da4d04cbce4d4209f7e88f8fc3532ef289a99e (diff) | |
download | gdb-ae6a105d22fb603dbfb956bbcedf9ae469323d55.zip gdb-ae6a105d22fb603dbfb956bbcedf9ae469323d55.tar.gz gdb-ae6a105d22fb603dbfb956bbcedf9ae469323d55.tar.bz2 |
value_maybe_namespace_elt: Remove unnecessary test of result != NULL.
Both allocate_value and value_of_variable are guaranteed to return non-NULL.
gdb/ChangeLog:
* valops.c (value_maybe_namespace_elt): Remove unnecessary test of
result != NULL.
Diffstat (limited to 'gdb/valops.c')
-rw-r--r-- | gdb/valops.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/valops.c b/gdb/valops.c index 4125fc0..4d3059e 100644 --- a/gdb/valops.c +++ b/gdb/valops.c @@ -3586,7 +3586,7 @@ value_maybe_namespace_elt (const struct type *curtype, else result = value_of_variable (sym, get_selected_block (0)); - if (result && want_address) + if (want_address) result = value_addr (result); return result; |