[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [snowflake/master] Remove unnecessary initialisation of last
commit 01156e58eb138200eea84b4ce3f86b251b991a19
Author: Shane Howearth <Shane.h.1@xxxxxxxxx>
Date: Thu Sep 26 13:37:32 2019 +1000
Remove unnecessary initialisation of last
last was initialised twice (creating a shadow), the second time inside
a case statement. The second initialisation is removed, keeping the use
of last aligned to the isame style as its use other parts of the case
statement.
---
client/lib/util.go | 1 -
1 file changed, 1 deletion(-)
diff --git a/client/lib/util.go b/client/lib/util.go
index f385279..f93bcbe 100644
--- a/client/lib/util.go
+++ b/client/lib/util.go
@@ -54,7 +54,6 @@ func (b *BytesSyncLogger) Log() {
case amount = <-b.OutboundChan:
b.Outbound += amount
b.OutEvents++
- last := time.Now()
if time.Since(last) > time.Second*LogTimeInterval {
last = time.Now()
output()
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits