mirror of
https://github.com/rwinkhart/sys.git
synced 2026-08-28 04:46:44 -04:00
unix: fix TestFchmodat on illumos
Like linux/android, illumos doesn't support Fchmodat flags != 0. The comment already mentions this, so update the condition as well now that GOOS illumos is known. Change-Id: Ic6542223129ec5fd8bb56dab3c8a042dc29ec7cc Reviewed-on: https://go-review.googlesource.com/c/sys/+/179362 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
committed by
Tobias Klauser
parent
46560c3f3c
commit
69e3a3a65b
@@ -643,7 +643,8 @@ func TestFchmodat(t *testing.T) {
|
||||
didChmodSymlink := true
|
||||
err = unix.Fchmodat(unix.AT_FDCWD, "symlink1", uint32(mode), unix.AT_SYMLINK_NOFOLLOW)
|
||||
if err != nil {
|
||||
if (runtime.GOOS == "android" || runtime.GOOS == "linux" || runtime.GOOS == "solaris") && err == unix.EOPNOTSUPP {
|
||||
if (runtime.GOOS == "android" || runtime.GOOS == "linux" ||
|
||||
runtime.GOOS == "solaris" || runtime.GOOS == "illumos") && err == unix.EOPNOTSUPP {
|
||||
// Linux and Illumos don't support flags != 0
|
||||
didChmodSymlink = false
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user