[PATCH 5/5] Update sub-variables of the one we are looking at



This is a bug fix to our varobjs diff handling utility.  We were
forgetting to apply the varobj diff to the sub-variables of a given
varobj.

Fixed thus, tested an applying to master.

	* src/dbgengine/nmv-dbg-common.cc (VarChange::apply_to_variable):
	Don't forget to apply changes to the sub-variables of the one we
	are looking at.
---
 src/dbgengine/nmv-dbg-common.cc |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/src/dbgengine/nmv-dbg-common.cc b/src/dbgengine/nmv-dbg-common.cc
index c440a8d..3329d2e 100644
--- a/src/dbgengine/nmv-dbg-common.cc
+++ b/src/dbgengine/nmv-dbg-common.cc
@@ -162,15 +162,13 @@ VarChange::apply_to_variable (IDebugger::VariableSafePtr a_var,
     IDebugger::VariableSafePtr v;
     if (*a_var == *variable ()) {
         applied_to = a_var;
-        update_debugger_variable (*applied_to, *variable ());
     } else {
         // variable must be a descendant of a_var.
         v = a_var->get_descendant (variable ()->internal_name ());
         THROW_IF_FAIL (v);
         applied_to = v;
-        if (variable ()->name ().empty () && !v->name ().empty ())
-            variable ()->name (v->name ());
     }
+    update_debugger_variable (*applied_to, *variable ());
 
     a_changed_vars.push_back (applied_to);
 
-- 
		Dodji


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]