refactor: remove superfluous var

conn.shutdown was only set/accessed in handleShutdown, which in turn
is only called on termination of queryLoop and hence multiple
invocations are impossible.
This commit is contained in:
Matthias Radestock committed 2015-01-12 18:39:25 +00:00
1 parent aed95326f3
commit 1e4d7e4462
2 files changed
-5

No files matched your search

-4
View File
@@ -269,10 +269,6 @@ func (conn *LocalConnection) handleShutdown() {
// (or write elements which are only read by the same
// process). Taking locks is only done for elements which are read
// by other processes.
if conn.shutdown {
return
}
conn.shutdown = true
if conn.TCPConn != nil {
checkWarn(conn.TCPConn.Close())
-1
View File
@@ -60,7 +60,6 @@ type LocalConnection struct {
Decryptor Decryptor
Router *Router
UID uint64
shutdown bool
queryChan chan<- *ConnectionInteraction
}