Bug 351103 - Java files open when inspecting the code, instead of Class file - 3.4.2+
diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaSourceLookupUtil.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaSourceLookupUtil.java
index 87669ca..90d6715 100644
--- a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaSourceLookupUtil.java
+++ b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaSourceLookupUtil.java
@@ -19,7 +19,6 @@
 import org.eclipse.core.resources.IResource;
 import org.eclipse.core.resources.ResourcesPlugin;
 import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
 import org.eclipse.debug.core.sourcelookup.ISourceContainer;
 import org.eclipse.debug.core.sourcelookup.containers.DirectorySourceContainer;
 import org.eclipse.debug.core.sourcelookup.containers.ExternalArchiveSourceContainer;
@@ -172,7 +171,7 @@
 		// External jars are shared, so it does not matter which project it
 		// originates from
 		IJavaModel model = JavaCore.create(ResourcesPlugin.getWorkspace().getRoot());
-		Path entryPath = new Path(entry.getLocation());
+		IPath entryPath = entry.getPath();
 		try {
 			IJavaProject[] jps = model.getJavaProjects();
 			for (int i = 0; i < jps.length; i++) {
@@ -182,7 +181,7 @@
 					IPackageFragmentRoot[] allRoots = jp.getPackageFragmentRoots();
 					for (int j = 0; j < allRoots.length; j++) {
 						IPackageFragmentRoot root = allRoots[j];
-						if (root.isExternal() && root.getPath().equals(entryPath)) {
+						if (root.getPath().equals(entryPath)) {
 							if (isSourceAttachmentEqual(root, entry)) {
 								// use package fragment root
 								return root;