Changeset 1831 for trunk/org.modelica.mdt.debug.core/src/org/modelica/mdt
- Timestamp:
- 10/08/13 10:28:34 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/org.modelica.mdt.debug.core/src/org/modelica/mdt/debug/gdb/core/model/thread/GDBThread.java
r1512 r1831 45 45 import org.eclipse.debug.core.model.IStackFrame; 46 46 import org.eclipse.debug.core.model.IThread; 47 import org.modelica.mdt.core.preferences.PreferenceManager; 47 48 import org.modelica.mdt.debug.core.MDTDebugCorePlugin; 48 49 import org.modelica.mdt.debug.core.launcher.IMDTConstants; … … 106 107 public List<GDBStackFrame> fGDBStackFrames = null; 107 108 private GDBStackFrame fCurrentGDBStackFrame = null; 108 private final static int MAX_STACK_DEPTH = 100; 109 /* get it from preferences and if is -1 assign it inside getStackInfoDepth! */ 110 private static int MAX_STACK_DEPTH = 111 Integer.parseInt(PreferenceManager.getOMCGDBMaxStackDepth()); 109 112 private Boolean fRefreshStackFrames = true; 110 113 public enum ExecuteCommand { … … 202 205 // get the stack depth 203 206 int depth = getStackInfoDepth(); 204 if (depth > =getMaxStackDepth())207 if (depth > getMaxStackDepth()) 205 208 depth = getMaxStackDepth() - 1; 206 209 // get the stack frames from GDB … … 384 387 * @return 385 388 */ 386 public int getStackInfoDepth() { 389 public int getStackInfoDepth() { 387 390 // TODO Auto-generated method stub 388 391 int stackDepth = 0; … … 419 422 // TODO Auto-generated catch block 420 423 MDTDebugCorePlugin.log(null, e); 424 stackDepth = 1; 421 425 } 422 426 } catch (MIException e) { 423 427 // 1 is safe to return 424 return 1; 425 } 428 stackDepth = 1; 429 } 430 if (MAX_STACK_DEPTH < 0) 431 MAX_STACK_DEPTH = stackDepth; 426 432 return stackDepth; 427 433 }
Note: See TracChangeset
for help on using the changeset viewer.