server: immediately return to caller when processing sendToPeer

This commit alters the logic of processing sendToPeer requests within
the server to immediately return to the caller after locating the
target peer.
This commit is contained in:
Olaoluwa Osuntokun 2017-02-02 16:57:20 -08:00
parent 3f6afa51b9
commit c1c1cabc4e
No known key found for this signature in database
GPG Key ID: 9CC5B105D03521A2
1 changed files with 2 additions and 2 deletions

View File

@ -640,11 +640,11 @@ out:
}
s.peersMtx.RUnlock()
sMsg.errChan <- nil
for _, msg := range sMsg.msgs {
targetPeer.queueMsg(msg, nil)
}
sMsg.errChan <- nil
}()
case query := <-s.queries:
switch msg := query.(type) {