From b853bb6095179c56c8605b1da920b5b3bda21f67 Mon Sep 17 00:00:00 2001 From: Rasmus Dahlberg Date: Tue, 1 Jun 2021 10:20:24 +0200 Subject: use ioutil instead of io (go v1.14) --- types/ascii.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'types') diff --git a/types/ascii.go b/types/ascii.go index 565e52d..d27d79b 100644 --- a/types/ascii.go +++ b/types/ascii.go @@ -5,6 +5,7 @@ import ( "encoding/hex" "fmt" "io" + "io/ioutil" "strconv" ) @@ -64,7 +65,7 @@ type MessageASCII struct { // NewMessageASCII unpacks an incoming ASCII message func NewMessageASCII(r io.Reader, numFieldExpected int) (*MessageASCII, error) { - buf, err := io.ReadAll(r) + buf, err := ioutil.ReadAll(r) if err != nil { return nil, fmt.Errorf("ReadAll: %v", err) } -- cgit v1.2.3