aboutsummaryrefslogtreecommitdiff
path: root/gdb/varobj.c
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>2012-01-09 22:31:39 +0000
committerDoug Evans <dje@google.com>2012-01-09 22:31:39 +0000
commit3436505436d26654ff014fe4c3a115dbc3fc8464 (patch)
tree43bb0f549c1d64c67fb9ca251c5d5a3021d4c2ba /gdb/varobj.c
parent696166a3767cfd209c2445b4a358241dc6e7157a (diff)
downloadgdb-3436505436d26654ff014fe4c3a115dbc3fc8464.zip
gdb-3436505436d26654ff014fe4c3a115dbc3fc8464.tar.gz
gdb-3436505436d26654ff014fe4c3a115dbc3fc8464.tar.bz2
* gdbtypes.c (safe_parse_type): Initialize type to keep gcc happy.
* varobj.c (varobj_set_value): Initialize val,value to keep gcc happy.
Diffstat (limited to 'gdb/varobj.c')
-rw-r--r--gdb/varobj.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/gdb/varobj.c b/gdb/varobj.c
index b17d3fd..9c3166d 100644
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -1359,13 +1359,12 @@ varobj_get_value (struct varobj *var)
int
varobj_set_value (struct varobj *var, char *expression)
{
- struct value *val;
-
+ struct value *val = NULL; /* Initialize to keep gcc happy. */
/* The argument "expression" contains the variable's new value.
We need to first construct a legal expression for this -- ugh! */
/* Does this cover all the bases? */
struct expression *exp;
- struct value *value;
+ struct value *value = NULL; /* Initialize to keep gcc happy. */
int saved_input_radix = input_radix;
char *s = expression;
volatile struct gdb_exception except;