[java] Handle cancellation during the search for JDK

GitOrigin-RevId: 2ec8bd5b62d618ba0c3c414fd6dd54ef75bd0687
This commit is contained in:
Konstantin.Nisht
2025-01-03 18:44:38 +00:00
committed by intellij-monorepo-bot
parent cf7f17cf93
commit 2521f8c2a9
@@ -144,6 +144,9 @@ public class JavaHomeFinderBasic {
return scanAll(dirsToCheck, false);
}
catch (CancellationException e) {
throw e;
}
catch (Exception e) {
log.warn("Failed to scan PATH for JDKs. " + e.getMessage(), e);
return Collections.emptySet();