mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
refactor: move from io/ioutil to io and os package
The io/ioutil package has been deprecated in Go 1.16. This commit replaces the existing io/ioutil functions with their new definitions in io and os packages. Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
This commit is contained in:
@@ -6,7 +6,7 @@ package main
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"math/rand"
|
||||
"strings"
|
||||
"testing"
|
||||
@@ -41,7 +41,7 @@ func (s *DockerSuite) TestContainersAPICreateMountsBindNamedPipe(c *testing.T) {
|
||||
go func() {
|
||||
conn, err := l.Accept()
|
||||
if err == nil {
|
||||
b, err = ioutil.ReadAll(conn)
|
||||
b, err = io.ReadAll(conn)
|
||||
conn.Close()
|
||||
}
|
||||
ch <- err
|
||||
|
||||
Reference in New Issue
Block a user