issue 384: fixed GuestAdditions LiveTest - Adrian comments addressed

This commit is contained in:
andreaturli 2012-02-19 10:59:45 +00:00
parent 290c5d5f47
commit 328621e961
1 changed files with 3 additions and 9 deletions

View File

@ -139,7 +139,7 @@ public class VirtualBoxComputeServiceAdapter implements ComputeServiceAdapter<IM
machineSession.getConsole().resume(); machineSession.getConsole().resume();
machineSession.unlockMachine(); machineSession.unlockMachine();
} catch (Exception e) { } catch (Exception e) {
propogate(e); throw Throwables.propagate(e);
} }
} }
@ -152,16 +152,10 @@ public class VirtualBoxComputeServiceAdapter implements ComputeServiceAdapter<IM
machineSession.getConsole().pause(); machineSession.getConsole().pause();
machineSession.unlockMachine(); machineSession.unlockMachine();
} catch (Exception e) { } catch (Exception e) {
propogate(e); throw Throwables.propagate(e);
} }
} }
protected <T> T propogate(Exception e) {
Throwables.propagate(e);
assert false;
return null;
}
private void launchVMProcess(IMachine machine, ISession session) { private void launchVMProcess(IMachine machine, ISession session) {
IProgress prog = machine.launchVMProcess(session, "gui", ""); IProgress prog = machine.launchVMProcess(session, "gui", "");
prog.waitForCompletion(-1); prog.waitForCompletion(-1);
@ -184,7 +178,7 @@ public class VirtualBoxComputeServiceAdapter implements ComputeServiceAdapter<IM
} }
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); throw Throwables.propagate(e);
} }
} }
} }