mirror of
https://github.com/containers/podman.git
synced 2025-10-18 03:33:32 +08:00
enable staticcheck linter
Fix many problems reported by the staticcheck linter, including many real bugs! Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
@ -880,11 +880,11 @@ func (p *PodmanTestIntegration) makeOptions(args []string, noEvents, noCache boo
|
||||
|
||||
func writeConf(conf []byte, confPath string) {
|
||||
if _, err := os.Stat(filepath.Dir(confPath)); os.IsNotExist(err) {
|
||||
if err := os.MkdirAll(filepath.Dir(confPath), 777); err != nil {
|
||||
if err := os.MkdirAll(filepath.Dir(confPath), 0o777); err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
}
|
||||
if err := ioutil.WriteFile(confPath, conf, 777); err != nil {
|
||||
if err := ioutil.WriteFile(confPath, conf, 0o777); err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user