umask.go 318 B

1234567891011121314
  1. //go:build !windows
  2. // +build !windows
  3. package system // import "github.com/docker/docker/pkg/system"
  4. import (
  5. "golang.org/x/sys/unix"
  6. )
  7. // Umask sets current process's file mode creation mask to newmask
  8. // and returns oldmask.
  9. func Umask(newmask int) (oldmask int, err error) {
  10. return unix.Umask(newmask), nil
  11. }