mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-22 14:12:10 +02:00
Fix for bug264721
This commit is contained in:
parent
5008c01caf
commit
0465eb3d20
2 changed files with 38 additions and 9 deletions
|
@ -460,6 +460,11 @@ public class MIBreakpoints extends AbstractDsfService implements IBreakpoints
|
||||||
Integer lineNumber = (Integer) getProperty(attributes, LINE_NUMBER, -1);
|
Integer lineNumber = (Integer) getProperty(attributes, LINE_NUMBER, -1);
|
||||||
String function = (String) getProperty(attributes, FUNCTION, NULL_STRING);
|
String function = (String) getProperty(attributes, FUNCTION, NULL_STRING);
|
||||||
|
|
||||||
|
// Fix for Bug264721
|
||||||
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
|
||||||
if (!fileName.equals(NULL_STRING)) {
|
if (!fileName.equals(NULL_STRING)) {
|
||||||
if (lineNumber != -1) {
|
if (lineNumber != -1) {
|
||||||
location = fileName + ":" + lineNumber; //$NON-NLS-1$
|
location = fileName + ":" + lineNumber; //$NON-NLS-1$
|
||||||
|
|
|
@ -1718,7 +1718,11 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void updateWatchpoint_AddCondition() throws Throwable {
|
public void updateWatchpoint_AddCondition() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_1, true);
|
String fileName = SOURCE_FILE;
|
||||||
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_1, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
@ -1769,7 +1773,11 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void updateWatchpoint_RemoveCondition() throws Throwable {
|
public void updateWatchpoint_RemoveCondition() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_1, true);
|
String fileName = SOURCE_FILE;
|
||||||
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_1, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
@ -1821,7 +1829,11 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void updateWatchpoint_ModifyCondition() throws Throwable {
|
public void updateWatchpoint_ModifyCondition() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_1, true);
|
String fileName = SOURCE_FILE;
|
||||||
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_1, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
@ -2640,8 +2652,12 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void breakpointHit_watchpointUpdateCount() throws Throwable {
|
public void breakpointHit_watchpointUpdateCount() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_3, true);
|
String fileName = SOURCE_FILE;
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_4, true);
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_3, true);
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_4, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
@ -2707,8 +2723,12 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void breakpointHit_watchpointUpdateCondition() throws Throwable {
|
public void breakpointHit_watchpointUpdateCondition() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_3, true);
|
String fileName = SOURCE_FILE;
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_4, true);
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_3, true);
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_4, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
@ -2774,8 +2794,12 @@ public class MIBreakpointsTest extends BaseTestCase {
|
||||||
public void breakpointHit_WatchpointOutOfScope() throws Throwable {
|
public void breakpointHit_WatchpointOutOfScope() throws Throwable {
|
||||||
|
|
||||||
// Run to the point where the variable is initialized
|
// Run to the point where the variable is initialized
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_1, true);
|
String fileName = SOURCE_FILE;
|
||||||
SyncUtil.SyncAddBreakpoint(SOURCE_FILE + ":" + LINE_NUMBER_3, true);
|
if (fileName.contains(" ")) { //$NON-NLS-1$
|
||||||
|
fileName = "\"" + fileName + "\""; //$NON-NLS-1$//$NON-NLS-2$
|
||||||
|
}
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_1, true);
|
||||||
|
SyncUtil.SyncAddBreakpoint(fileName + ":" + LINE_NUMBER_3, true);
|
||||||
SyncUtil.SyncResumeUntilStopped();
|
SyncUtil.SyncResumeUntilStopped();
|
||||||
clearEventCounters();
|
clearEventCounters();
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue