peer: increase initial handshake timeout to 15 seconds

This commit is contained in:
Olaoluwa Osuntokun committed 2017-04-13 14:48:43 -07:00
1 parent 5442e42cc1
commit b51a0eb094
1 file changed
+2 -2
+2 -2
View File
@@ -304,8 +304,8 @@ func (p *peer) Start() error {
select {
// In order to avoid blocking indefinitely, we'll give the other peer
// an upper timeout of 5 seconds to respond before we bail out early.
case <-time.After(time.Second * 5):
// an upper timeout of 15 seconds to respond before we bail out early.
case <-time.After(time.Second * 15):
return fmt.Errorf("peer did not complete handshake within 5 " +
"seconds")
case err := <-readErr: