mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
![Kir Kolyshkin](/assets/img/avatar_default.png)
This is to include the Go 1.11 fix
(https://github.com/containerd/continuity/pull/120).
Again (see c64a2448d1
).
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
14 lines
303 B
Go
14 lines
303 B
Go
// +build darwin freebsd solaris
|
|
|
|
package driver
|
|
|
|
import (
|
|
"os"
|
|
|
|
"golang.org/x/sys/unix"
|
|
)
|
|
|
|
// Lchmod changes the mode of a file not following symlinks.
|
|
func (d *driver) Lchmod(path string, mode os.FileMode) error {
|
|
return unix.Fchmodat(unix.AT_FDCWD, path, uint32(mode), unix.AT_SYMLINK_NOFOLLOW)
|
|
}
|