mirror of
https://github.com/samba-team/samba.git
synced 2025-01-10 01:18:15 +03:00
utils: Tweak exception handling to stop flake8 complaining
Don't bother with "as e" to avoid warning about unused variable. Don't use bare "except:" (though pylint still complains about this version). Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jose A. Rivera <jarrpa@samba.org>
This commit is contained in:
parent
12d3e215a6
commit
98c7a38b71
@ -196,10 +196,10 @@ def main():
|
||||
break
|
||||
os.kill(ppid, 0)
|
||||
time.sleep(etcd_config['lock_refresh'])
|
||||
except (OSError, SystemExit) as e:
|
||||
except (OSError, SystemExit):
|
||||
if lock is not None and lock.is_acquired:
|
||||
lock.release()
|
||||
except:
|
||||
except Exception:
|
||||
print_nonl(3)
|
||||
if logging.getLogger().getEffectiveLevel() == logging.DEBUG:
|
||||
raise
|
||||
|
Loading…
Reference in New Issue
Block a user