Skip to content

Commit

Permalink
Merge pull request nsqio#950 from 1050676515/master
Browse files Browse the repository at this point in the history
nsqlookupd: minor optimizations
  • Loading branch information
mreiferson authored Oct 19, 2017
2 parents da81dd2 + d07707b commit 220ca47
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions nsqlookupd/registration_db.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ func (r *RegistrationDB) AddProducer(k Registration, p *Producer) bool {
for _, producer := range producers {
if producer.peerInfo.id == p.peerInfo.id {
found = true
break
}
}
if found == false {
Expand Down
1 change: 1 addition & 0 deletions nsqlookupd/tcp.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ func (p *tcpServer) Handle(clientConn net.Conn) {
_, err := io.ReadFull(clientConn, buf)
if err != nil {
p.ctx.nsqlookupd.logf(LOG_ERROR, "failed to read protocol version - %s", err)
clientConn.Close()
return
}
protocolMagic := string(buf)
Expand Down

0 comments on commit 220ca47

Please sign in to comment.