1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-03 23:25:26 +02:00

handling wierd case where the location of a project is null

This commit is contained in:
David McKnight 2007-05-08 19:38:32 +00:00
parent c8694926f3
commit 26ca200828

View file

@ -730,7 +730,9 @@ class RemoteExportWizardPage1 extends WizardExportResourcesPage implements Liste
if (root.getLocation().isPrefixOf(testPath)) return "workspace root"; //UniversalSystemPlugin.getString("IFSexport.rootName"); //$NON-NLS-1$
IProject[] projects = root.getProjects();
for (int i = 0; i < projects.length; i++) {
if (projects[i].getLocation().isPrefixOf(testPath)) return projects[i].getName();
IPath loc = projects[i].getLocation();
if (loc != null && loc.isPrefixOf(testPath))
return projects[i].getName();
}
return null;
}