[nemiver/follow-fork-mode: 26/35] Don't clear search dir paths when restarting the inferior



commit 42947bde05430dfb75338a1bb380ed31ebe75eb5
Author: Dodji Seketeli <dodji gnome org>
Date:   Mon Apr 26 19:15:29 2010 +0200

    Don't clear search dir paths when restarting the inferior
    
    	* src/persp/dbgperspective/nmv-dbg-perspective.cc
    	(DBGPerspective::execute_last_program_in_memory): Do not clear
    	session data when restarting the same inferior. E.g. do not
    	clear the search dirs path.

 src/persp/dbgperspective/nmv-dbg-perspective.cc |   20 ++++++--------------
 1 files changed, 6 insertions(+), 14 deletions(-)
---
diff --git a/src/persp/dbgperspective/nmv-dbg-perspective.cc b/src/persp/dbgperspective/nmv-dbg-perspective.cc
index cd32d1b..2262a8f 100644
--- a/src/persp/dbgperspective/nmv-dbg-perspective.cc
+++ b/src/persp/dbgperspective/nmv-dbg-perspective.cc
@@ -6374,20 +6374,12 @@ DBGPerspective::execute_program ()
 void
 DBGPerspective::execute_last_program_in_memory ()
 {
-    if (!m_priv->prog_path.empty ()) {
-        vector<IDebugger::Breakpoint> breakpoints;
-        map<int, IDebugger::Breakpoint>::const_iterator it;
-        for (it = m_priv->breakpoints.begin ();
-             it != m_priv->breakpoints.end ();
-             ++it) {
-            breakpoints.push_back (it->second);
-        }
-        execute_program (m_priv->prog_path, m_priv->prog_args,
-                         m_priv->env_variables, m_priv->prog_cwd,
-                         breakpoints,
-                         false,
-                         false /* don't close opened files */);
-    }
+    vector<IDebugger::Breakpoint> bps;
+    execute_program (m_priv->prog_path, m_priv->prog_args,
+                     m_priv->env_variables, m_priv->prog_cwd,
+                     bps,
+                     true /* be aware we are restarting the same inferior*/,
+                     false /* don't close opened files */);
 }
 
 void



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