mirror of
https://github.com/containers/podman.git
synced 2026-03-18 06:38:49 -04:00
Replace deprecated ioutil
Package `io/ioutil` was deprecated in golang 1.16, preventing podman from building under Fedora 37. Fortunately, functionality identical replacements are provided by the packages `io` and `os`. Replace all usage of all `io/ioutil` symbols with appropriate substitutions according to the golang docs. Signed-off-by: Chris Evich <cevich@redhat.com>
This commit is contained in:
@@ -4,7 +4,6 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"net"
|
||||
"os"
|
||||
"strings"
|
||||
@@ -49,7 +48,7 @@ type NotifyProxy struct {
|
||||
|
||||
// New creates a NotifyProxy. The specified temp directory can be left empty.
|
||||
func New(tmpDir string) (*NotifyProxy, error) {
|
||||
tempFile, err := ioutil.TempFile(tmpDir, "-podman-notify-proxy.sock")
|
||||
tempFile, err := os.CreateTemp(tmpDir, "-podman-notify-proxy.sock")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user