Bugfix: Don't load the systray in a 64bit JVM in Windows (closes #506)

This commit is contained in:
kytv
2011-08-17 21:20:21 +00:00
parent a9f943154c
commit 3f979b159d
3 changed files with 8 additions and 2 deletions

View File

@ -37,6 +37,8 @@ public class SysTray implements SysTrayMenuListener {
private static String _portString;
private static boolean _showIcon;
private static UrlLauncher _urlLauncher = new UrlLauncher();
private static final boolean _is64 = "64".equals(System.getProperty("sun.arch.data.model")) ||
System.getProperty("os.arch").contains("64");
static {
File config = new File(I2PAppContext.getGlobalContext().getConfigDir(), "systray.config");
@ -52,7 +54,7 @@ public class SysTray implements SysTrayMenuListener {
//if (!(new File("router.config")).exists())
// openRouterConsole("http://localhost:" + _portString + "/index.jsp");
if ( (System.getProperty("os.name").startsWith("Windows")) && (!Boolean.getBoolean("systray.disable")) )
if ( (System.getProperty("os.name").startsWith("Windows")) && (!Boolean.getBoolean("systray.disable")) && (!_is64))
_instance = new SysTray();
}