From 66e309c5c4fb1faebe7338053481024eeb55a2d1 Mon Sep 17 00:00:00 2001 From: obscuren Date: Tue, 16 Sep 2014 16:36:18 +0200 Subject: [PATCH] Up deadline to reduce cpu load --- ethwire/messaging.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ethwire/messaging.go b/ethwire/messaging.go index 4f4393a9d1..2161ce27fd 100644 --- a/ethwire/messaging.go +++ b/ethwire/messaging.go @@ -96,7 +96,7 @@ func ReadMessages(conn net.Conn) (msgs []*Msg, err error) { for { // Give buffering some time - conn.SetReadDeadline(time.Now().Add(5 * time.Millisecond)) + conn.SetReadDeadline(time.Now().Add(100 * time.Millisecond)) // Create a new temporarily buffer b := make([]byte, 1440) n, _ := conn.Read(b)