mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
Allow system.MkDirAll() to be used as drop-in for os.MkDirAll()
also renamed the non-windows variant of this file to be consistent with other files in this package Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -37,7 +37,7 @@ func New(path string) (*PIDFile, error) {
|
||||
return nil, err
|
||||
}
|
||||
// Note MkdirAll returns nil if a directory already exists
|
||||
if err := system.MkdirAll(filepath.Dir(path), os.FileMode(0755), ""); err != nil {
|
||||
if err := system.MkdirAll(filepath.Dir(path), os.FileMode(0755)); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := ioutil.WriteFile(path, []byte(fmt.Sprintf("%d", os.Getpid())), 0644); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user