Skip to main content
summaryrefslogtreecommitdiffstats
path: root/debug
diff options
context:
space:
mode:
authorSergey Prigogin2010-12-16 13:04:38 -0500
committerSergey Prigogin2010-12-16 13:04:38 -0500
commit850511bfd325a9f3f5ba5923c65b7e8ffadb0233 (patch)
tree169b64b56ce3b0b2510dc7dc13b2fa9b6ca84b83 /debug
parentf8cb160e205e0088b2a16efd9aeaf605247b6e83 (diff)
downloadorg.eclipse.cdt-850511bfd325a9f3f5ba5923c65b7e8ffadb0233.tar.gz
org.eclipse.cdt-850511bfd325a9f3f5ba5923c65b7e8ffadb0233.tar.xz
org.eclipse.cdt-850511bfd325a9f3f5ba5923c65b7e8ffadb0233.zip
Added a missing condition.
Diffstat (limited to 'debug')
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/sourcelookup/CProjectSourceContainer.java18
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/SourceFoldersRelativePathSourceContainer.java2
2 files changed, 10 insertions, 10 deletions
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/sourcelookup/CProjectSourceContainer.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/sourcelookup/CProjectSourceContainer.java
index 2f85324855..ea6e02f5ce 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/sourcelookup/CProjectSourceContainer.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/sourcelookup/CProjectSourceContainer.java
@@ -89,16 +89,16 @@ public class CProjectSourceContainer extends CompositeSourceContainer {
super.init(director);
if (fProject == null && director != null) {
fProject = SourceUtils.getLaunchConfigurationProject(director);
- if (fProject != null) {
- fRootURI = fProject.getLocationURI();
- if (fRootURI == null)
- return;
- try {
- fRootFile = EFS.getStore(fRootURI);
- } catch (CoreException e) {
- }
- fRoot = ResourcesPlugin.getWorkspace().getRoot();
+ }
+ if (fProject != null) {
+ fRootURI = fProject.getLocationURI();
+ if (fRootURI == null)
+ return;
+ try {
+ fRootFile = EFS.getStore(fRootURI);
+ } catch (CoreException e) {
}
+ fRoot = ResourcesPlugin.getWorkspace().getRoot();
}
}
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/SourceFoldersRelativePathSourceContainer.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/SourceFoldersRelativePathSourceContainer.java
index 7b03ffade3..862fa2617b 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/SourceFoldersRelativePathSourceContainer.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/SourceFoldersRelativePathSourceContainer.java
@@ -73,7 +73,7 @@ public class SourceFoldersRelativePathSourceContainer extends CompositeSourceCon
@Override
public void init(ISourceLookupDirector director) {
super.init(director);
- if (director != null) {
+ if (fProject == null && director != null) {
fProject = SourceUtils.getLaunchConfigurationProject(director);
}
}

Back to the top