aboutsummaryrefslogtreecommitdiff
path: root/src/syscall
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@distanz.ch>2018-08-21 08:28:16 +0200
committerTobias Klauser <tobias.klauser@gmail.com>2018-08-21 14:08:12 +0000
commite8daca4c482320cecff9c31bbd60f25351d49756 (patch)
tree8ce569ef9d05062460a19faefae0a99ea70d0925 /src/syscall
parent1040626c0ce4a1bc2b312aa0866ffeb2ff53c1ab (diff)
downloadgo-e8daca4c482320cecff9c31bbd60f25351d49756.tar.xz
syscall: add S_IRWXG and S_IRWXO on DragonflyBSD
As discussed in CL 126621, these constants are already defined on Linux, Darwin, FreeBSD and NetBSD. In order to ensure portability of existing code using the syscall package, provide them for DragonflyBSD (and OpenBSD, in a separate CL) as well. Change-Id: I708c60f75f787a410bdfa4ceebd2825874e92511 Reviewed-on: https://go-review.googlesource.com/130335 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src/syscall')
-rw-r--r--src/syscall/types_dragonfly.go2
-rw-r--r--src/syscall/ztypes_dragonfly_amd64.go2
2 files changed, 4 insertions, 0 deletions
diff --git a/src/syscall/types_dragonfly.go b/src/syscall/types_dragonfly.go
index 0c060d932e..53bc12403b 100644
--- a/src/syscall/types_dragonfly.go
+++ b/src/syscall/types_dragonfly.go
@@ -113,6 +113,8 @@ const ( // Directory mode bits
S_IRUSR = C.S_IRUSR
S_IWUSR = C.S_IWUSR
S_IXUSR = C.S_IXUSR
+ S_IRWXG = C.S_IRWXG
+ S_IRWXO = C.S_IRWXO
)
type Stat_t C.struct_stat
diff --git a/src/syscall/ztypes_dragonfly_amd64.go b/src/syscall/ztypes_dragonfly_amd64.go
index 1cb8608228..e9e811f776 100644
--- a/src/syscall/ztypes_dragonfly_amd64.go
+++ b/src/syscall/ztypes_dragonfly_amd64.go
@@ -71,6 +71,8 @@ const (
S_IRUSR = 0x100
S_IWUSR = 0x80
S_IXUSR = 0x40
+ S_IRWXG = 0x38
+ S_IRWXO = 0x7
)
type Stat_t struct {