From 2cf3cb3e9999a00ca21742f7a63c3cff15fce704 Mon Sep 17 00:00:00 2001 From: Vincenzo Maffione Date: Wed, 31 May 2017 14:16:22 +0200 Subject: examples: jfed-rlite: use try-finally --- examples/jfed-rlite.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'examples') diff --git a/examples/jfed-rlite.py b/examples/jfed-rlite.py index ce058eb..d80b56e 100755 --- a/examples/jfed-rlite.py +++ b/examples/jfed-rlite.py @@ -46,6 +46,9 @@ tb = jfed.Testbed(exp_name = args.expname, exp = rlite.Experiment(tb, nodes = [a, b]) -exp.swap_in() -exp.install_prototype() -exp.bootstrap_prototype() +try: + exp.swap_in() + exp.install_prototype() + exp.bootstrap_prototype() +finally: + exp.swap_out() -- cgit v1.2.3