Skip to content

Commit

Permalink
fixed fanpei91#70
Browse files Browse the repository at this point in the history
  • Loading branch information
fanpei91 committed Dec 16, 2018
1 parent 0e3e864 commit da3d576
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dht.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,8 @@ func newDHT(laddr string) (*dht, error) {
}

func (g *dht) listen() error {
buf := make([]byte, 8192)
for {
buf := make([]byte, 2048)
n, addr, err := g.conn.ReadFromUDP(buf)
if err == nil {
go g.onMessage(buf[:n], *addr)
Expand Down

0 comments on commit da3d576

Please sign in to comment.