From dfff255e89b92ef2d196b7210623d9a9a076572b Mon Sep 17 00:00:00 2001 From: pauget Date: Sun, 12 Jun 2005 17:53:28 +0200 Subject: [PATCH] Si un switch est pas joignable on continue quand mme. darcs-hash:20050612155328-41617-86094bfbe7e3d7a235a4579b835c35f2ce9e507d.gz --- gestion/hptools.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/gestion/hptools.py b/gestion/hptools.py index b72f6335..e4a10261 100755 --- a/gestion/hptools.py +++ b/gestion/hptools.py @@ -423,7 +423,11 @@ if __name__ == '__main__' : for sw in switchs : print sw - s = hpswitch(sw) - for cmd in cmds : - print s.send_cmd(cmd) + try: + # Au cas ou le switch ne répondrai pas + s = hpswitch(sw) + for cmd in cmds : + print s.send_cmd(cmd) + except : + print 'ERREUR'