提交 8fa5df88 authored 作者: Thomas Mueller's avatar Thomas Mueller

H2 Console: browser detection didn't work for Mac OS X with OpenJDK 1.7.

上级 7420a2e4
...@@ -529,7 +529,7 @@ public class Server extends Tool implements Runnable, ShutdownHandler { ...@@ -529,7 +529,7 @@ public class Server extends Tool implements Runnable, ShutdownHandler {
} }
if (osName.indexOf("windows") >= 0) { if (osName.indexOf("windows") >= 0) {
rt.exec(new String[] { "rundll32", "url.dll,FileProtocolHandler", url }); rt.exec(new String[] { "rundll32", "url.dll,FileProtocolHandler", url });
} else if (osName.indexOf("mac") >= 0) { } else if (osName.indexOf("mac") >= 0 || osName.indexOf("darwin") >= 0) {
// Mac OS: to open a page with Safari, use "open -a Safari" // Mac OS: to open a page with Safari, use "open -a Safari"
Runtime.getRuntime().exec(new String[] { "open", url }); Runtime.getRuntime().exec(new String[] { "open", url });
} else { } else {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论