Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Inglis2004-06-21 09:21:36 -0400
committerDavid Inglis2004-06-21 09:21:36 -0400
commita09023fa41ba90856517e92a3bc89dee8753c70d (patch)
tree01278fd57f054b3a1e2b121b80ea88a901fa76cd /launch/org.eclipse.cdt.launch
parentb0f3f77badd77203a102c5730089c783b52fd591 (diff)
downloadorg.eclipse.cdt-a09023fa41ba90856517e92a3bc89dee8753c70d.tar.gz
org.eclipse.cdt-a09023fa41ba90856517e92a3bc89dee8753c70d.tar.xz
org.eclipse.cdt-a09023fa41ba90856517e92a3bc89dee8753c70d.zip
fixed error when new config created with non-c project selected
Diffstat (limited to 'launch/org.eclipse.cdt.launch')
-rw-r--r--launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/ui/CMainTab.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/ui/CMainTab.java b/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/ui/CMainTab.java
index fded30e7b25..1cda4555925 100644
--- a/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/ui/CMainTab.java
+++ b/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/ui/CMainTab.java
@@ -362,6 +362,9 @@ public class CMainTab extends CLaunchConfigurationTab {
*/
protected IBinary[] getBinaryFiles(final ICProject cproject) {
final Display display;
+ if (cproject == null || !cproject.exists()) {
+ return null;
+ }
if (getShell() == null) {
display = LaunchUIPlugin.getShell().getDisplay();
} else {
@@ -533,7 +536,7 @@ public class CMainTab extends CLaunchConfigurationTab {
IBinary binary = null;
if (cElement instanceof ICProject) {
IBinary[] bins = getBinaryFiles((ICProject)cElement);
- if (bins.length == 1) {
+ if (bins != null && bins.length == 1) {
binary = bins[0];
}
}

Back to the top