From: Mark Wooding Date: Fri, 11 May 2018 23:45:59 +0000 (+0100) Subject: svc/connect.in: Compress the code a bit. X-Git-Tag: 1.5.0~86 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/tripe/commitdiff_plain/f688828b41c1125b07f4f2f57ec536b8f5229582 svc/connect.in: Compress the code a bit. Only whitespace changes. --- diff --git a/svc/connect.in b/svc/connect.in index 37714252..607a6561 100644 --- a/svc/connect.in +++ b/svc/connect.in @@ -467,19 +467,15 @@ class PingPeer (object): me._ping() elif code == 'FAIL': S.notify('connect', 'ping-failed', me._peer, *stuff) - if not stuff: - pass - elif stuff[0] == 'unknown-peer': - me._pinger.kill(me._peer) - elif stuff[0] == 'ping-send-failed': - me._reconnect() + if not stuff: pass + elif stuff[0] == 'unknown-peer': me._pinger.kill(me._peer) + elif stuff[0] == 'ping-send-failed': me._reconnect() elif code == 'INFO': outcome = stuff[0] if outcome == 'ping-ok' and me._sabotage: outcome = 'ping-timeout' if outcome == 'ping-ok': - if me._failures > 0: - S.warn('connect', 'ping-ok', me._peer) + if me._failures > 0: S.warn('connect', 'ping-ok', me._peer) t = float(stuff[1]) me._last = '%.1fms' % t me._sigma_t += t