aboutsummaryrefslogtreecommitdiff
path: root/pkg/domain
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-09-12 06:50:48 +0200
committerGitHub <noreply@github.com>2022-09-12 06:50:48 +0200
commit1635fe8620fa454647cf7db2af9ed0c9b52eacfb (patch)
tree814768e6b942e199a6974e2f60a7082a004def18 /pkg/domain
parent940d3d889221e21cc24705381b2c2d11d75f39bf (diff)
parent118546c6a70704a7b19cb99f3c948b28264628de (diff)
downloadpodman-1635fe8620fa454647cf7db2af9ed0c9b52eacfb.tar.gz
podman-1635fe8620fa454647cf7db2af9ed0c9b52eacfb.tar.bz2
podman-1635fe8620fa454647cf7db2af9ed0c9b52eacfb.zip
Merge pull request #15737 from Juneezee/refactor/os.ReadDir
refactor: use `os.ReadDir` for lightweight directory reading
Diffstat (limited to 'pkg/domain')
-rw-r--r--pkg/domain/infra/abi/containers.go3
-rw-r--r--pkg/domain/infra/abi/images.go2
2 files changed, 2 insertions, 3 deletions
diff --git a/pkg/domain/infra/abi/containers.go b/pkg/domain/infra/abi/containers.go
index dfa3c5ba0..569fe8133 100644
--- a/pkg/domain/infra/abi/containers.go
+++ b/pkg/domain/infra/abi/containers.go
@@ -4,7 +4,6 @@ import (
"context"
"errors"
"fmt"
- "io/ioutil"
"os"
"strconv"
"sync"
@@ -858,7 +857,7 @@ func makeExecConfig(options entities.ExecOptions, rt *libpod.Runtime) (*libpod.E
func checkExecPreserveFDs(options entities.ExecOptions) error {
if options.PreserveFDs > 0 {
- entries, err := ioutil.ReadDir("/proc/self/fd")
+ entries, err := os.ReadDir("/proc/self/fd")
if err != nil {
return err
}
diff --git a/pkg/domain/infra/abi/images.go b/pkg/domain/infra/abi/images.go
index f9839f62f..3030bac20 100644
--- a/pkg/domain/infra/abi/images.go
+++ b/pkg/domain/infra/abi/images.go
@@ -869,7 +869,7 @@ func execTransferPodman(execUser *user.User, command []string, needToTag bool) (
func getSigFilename(sigStoreDirPath string) (string, error) {
sigFileSuffix := 1
- sigFiles, err := ioutil.ReadDir(sigStoreDirPath)
+ sigFiles, err := os.ReadDir(sigStoreDirPath)
if err != nil {
return "", err
}