From 335ede07f885c9798ddbb5d6159c7e9e5dde6f0c Mon Sep 17 00:00:00 2001 From: matst80 Date: Mon, 11 Nov 2024 21:43:31 +0100 Subject: [PATCH] less waiting --- tcp-cart-client.go | 2 +- tcp-client.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tcp-cart-client.go b/tcp-cart-client.go index 12714b2..47fb459 100644 --- a/tcp-cart-client.go +++ b/tcp-cart-client.go @@ -100,7 +100,7 @@ func (m *CartTCPClient) Call(messageType uint32, id CartId, responseType uint32, select { case ret := <-packetChan: return ret, nil - case <-time.After(3 * time.Second): + case <-time.After(time.Second): return nil, fmt.Errorf("timeout") } } diff --git a/tcp-client.go b/tcp-client.go index 540ddc5..4d57572 100644 --- a/tcp-client.go +++ b/tcp-client.go @@ -104,7 +104,7 @@ func (m *TCPClient) Call(messageType uint32, responseType uint32, data []byte) ( select { case ret := <-packetChan: return ret, nil - case <-time.After(3 * time.Second): + case <-time.After(time.Second): return nil, fmt.Errorf("timeout") } }