diff --git a/rse/plugins/org.eclipse.dstore.core/src/org/eclipse/dstore/core/server/SecuredThread.java b/rse/plugins/org.eclipse.dstore.core/src/org/eclipse/dstore/core/server/SecuredThread.java index ed2f97cf172..b758673667d 100644 --- a/rse/plugins/org.eclipse.dstore.core/src/org/eclipse/dstore/core/server/SecuredThread.java +++ b/rse/plugins/org.eclipse.dstore.core/src/org/eclipse/dstore/core/server/SecuredThread.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008 IBM Corporation and others. + * Copyright (c) 2008, 2011 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -12,6 +12,7 @@ * Contributors: * Noriaki Takatsu (IBM) - [220126] [dstore][api][breaking] Single process server for multiple clients * Noriaki Takatsu (IBM) - [228335] [dstore][multithread] start() in SecuredThread class + * David McKnight (IBM) - [358301] [DSTORE] Hang during debug source look up *******************************************************************************/ package org.eclipse.dstore.core.server; @@ -129,6 +130,9 @@ public class SecuredThread extends Thread systemService.setThreadSecurity(_dataStore.getClient()); } } + catch (OutOfMemoryError err){ + System.exit(-1); + } catch (Throwable e) { e.printStackTrace(new PrintWriter(System.err)); @@ -169,5 +173,14 @@ public class SecuredThread extends Thread } } */ + + public void start(){ + try { + super.start(); + } + catch (OutOfMemoryError e){ + System.exit(-1); + } + } } diff --git a/rse/plugins/org.eclipse.rse.services.dstore/miners/org/eclipse/rse/dstore/universal/miners/EnvironmentMiner.java b/rse/plugins/org.eclipse.rse.services.dstore/miners/org/eclipse/rse/dstore/universal/miners/EnvironmentMiner.java index 81483296dc4..a0be29d19a5 100644 --- a/rse/plugins/org.eclipse.rse.services.dstore/miners/org/eclipse/rse/dstore/universal/miners/EnvironmentMiner.java +++ b/rse/plugins/org.eclipse.rse.services.dstore/miners/org/eclipse/rse/dstore/universal/miners/EnvironmentMiner.java @@ -19,6 +19,7 @@ * Noriaki Takatsu (IBM) - [226237] [dstore] Move the place where the ServerLogger instance is made * David McKnight (IBM) - [226561] [apidoc] Add API markup to RSE Javadocs where extend / implement is allowed * David McKnight (IBM) - [283613] [dstore] Create a Constants File for all System Properties we support + * David McKnight (IBM) - [358301] [DSTORE] Hang during debug source look up *******************************************************************************/ package org.eclipse.rse.dstore.universal.miners; @@ -239,6 +240,9 @@ public class EnvironmentMiner extends Miner _dataStore.refresh(_system); } + catch (OutOfMemoryError err){ + System.exit(-1); + } catch (IOException e) { System.err.println("Error getting System Environment Variables\n" + e.getMessage()); //$NON-NLS-1$