Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Marchi2015-02-11 19:11:56 +0000
committerMarc Khouzam2015-02-20 18:55:03 +0000
commit989d77bf7ae15a3b608efcaf7db202e125367aa8 (patch)
treefd977d582d61611a7254663ca1f4d7eb5fea0faa
parent6b512c3be4dbf4553ffa238b8009c97b2ea77487 (diff)
downloadorg.eclipse.cdt-989d77bf7ae15a3b608efcaf7db202e125367aa8.tar.gz
org.eclipse.cdt-989d77bf7ae15a3b608efcaf7db202e125367aa8.tar.xz
org.eclipse.cdt-989d77bf7ae15a3b608efcaf7db202e125367aa8.zip
Make disassembly default end address relative to start
As it is now, if you pass a start address but no end address (null), the disassembled range will be [startAddress, $pc + 100], which does not quite make sense. I think the intention was to have the default end address be whatever the start address is, + 100. Change-Id: I1399cc116ecde6cfbdb2f1ec54a181e64a7f4c5f Signed-off-by: Simon Marchi <simon.marchi@polymtl.ca>
-rw-r--r--dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIDisassembly.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIDisassembly.java b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIDisassembly.java
index 7c7106b55c0..f9dc5e8c21b 100644
--- a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIDisassembly.java
+++ b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIDisassembly.java
@@ -124,7 +124,7 @@ public class MIDisassembly extends AbstractDsfService implements IDisassembly {
}
String start = (startAddress != null) ? startAddress.toString() : "$pc"; //$NON-NLS-1$
- String end = (endAddress != null) ? endAddress.toString() : "$pc + 100"; //$NON-NLS-1$
+ String end = (endAddress != null) ? endAddress.toString() : start + " + 100"; //$NON-NLS-1$
fConnection.queueCommand(fCommandFactory.createMIDataDisassemble(context, start, end, mode),
new DataRequestMonitor<MIDataDisassembleInfo>(getExecutor(), drm) {
@Override
@@ -206,7 +206,7 @@ public class MIDisassembly extends AbstractDsfService implements IDisassembly {
}
String start = (startAddress != null) ? startAddress.toString() : "$pc"; //$NON-NLS-1$
- String end = (endAddress != null) ? endAddress.toString() : "$pc + 100"; //$NON-NLS-1$
+ String end = (endAddress != null) ? endAddress.toString() : start + " + 100"; //$NON-NLS-1$
fConnection.queueCommand(fCommandFactory.createMIDataDisassemble(context, start, end, mode),
new DataRequestMonitor<MIDataDisassembleInfo>(getExecutor(), drm) {
@Override

Back to the top