PR mi/11098:

* varobj.c (install_new_value): Handle case where new print_value
	is NULL.
This commit is contained in:
Tom Tromey 2010-03-03 18:32:44 +00:00
parent a0e0ef55c6
commit e8f781e227
2 changed files with 10 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2010-03-03 Tom Tromey <tromey@redhat.com>
PR mi/11098:
* varobj.c (install_new_value): Handle case where new print_value
is NULL.
2010-03-03 Dainis Jonitis <jonitis@gmail.com>
PR gdb/11345:

View File

@ -1593,7 +1593,10 @@ install_new_value (struct varobj *var, struct value *value, int initial)
{
xfree (print_value);
print_value = value_get_print_value (var->value, var->format, var);
if (!var->print_value || strcmp (var->print_value, print_value) != 0)
if ((var->print_value == NULL && print_value != NULL)
|| (var->print_value != NULL && print_value == NULL)
|| (var->print_value != NULL && print_value != NULL
&& strcmp (var->print_value, print_value) != 0))
changed = 1;
}
if (var->print_value)