File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 1818
1919import java .io .BufferedReader ;
2020import java .io .IOException ;
21+ import java .net .URI ;
2122import java .net .URISyntaxException ;
2223import java .nio .charset .StandardCharsets ;
2324import java .nio .file .Path ;
4041import org .eclipse .core .runtime .Platform ;
4142import org .eclipse .core .runtime .Status ;
4243import org .eclipse .core .runtime .SubMonitor ;
44+ import org .eclipse .core .runtime .URIUtil ;
4345import org .eclipse .core .runtime .jobs .Job ;
4446import org .eclipse .core .runtime .preferences .ConfigurationScope ;
4547import org .eclipse .core .runtime .preferences .IEclipsePreferences ;
@@ -269,7 +271,8 @@ private static Optional<Path> getInstallationLocation() {
269271 // https://help.eclipse.org/latest/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Freference%2Fmisc%2Fruntime-options.html&anchor=locations
270272 try {
271273 Location installLocation = Platform .getConfigurationLocation ();
272- return Optional .of (Path .of (installLocation .getURL ().toURI ())); // assume location has a file-URL
274+ URI location = URIUtil .toURI (installLocation .getURL ());
275+ return Optional .of (Path .of (location )); // assume location has a file-URL
273276 } catch (URISyntaxException e ) { // ignore
274277 }
275278 return Optional .empty ();
You can’t perform that action at this time.
0 commit comments