aboutsummaryrefslogtreecommitdiff
path: root/libgo/go/os/proc.go
diff options
context:
space:
mode:
Diffstat (limited to 'libgo/go/os/proc.go')
-rw-r--r--libgo/go/os/proc.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/libgo/go/os/proc.go b/libgo/go/os/proc.go
index 33a8b26..804128a 100644
--- a/libgo/go/os/proc.go
+++ b/libgo/go/os/proc.go
@@ -25,18 +25,29 @@ func init() {
func runtime_args() []string // in package runtime
// Getuid returns the numeric user id of the caller.
+//
+// On Windows, it returns -1.
func Getuid() int { return syscall.Getuid() }
// Geteuid returns the numeric effective user id of the caller.
+//
+// On Windows, it returns -1.
func Geteuid() int { return syscall.Geteuid() }
// Getgid returns the numeric group id of the caller.
+//
+// On Windows, it returns -1.
func Getgid() int { return syscall.Getgid() }
// Getegid returns the numeric effective group id of the caller.
+//
+// On Windows, it returns -1.
func Getegid() int { return syscall.Getegid() }
// Getgroups returns a list of the numeric ids of groups that the caller belongs to.
+//
+// On Windows, it returns syscall.EWINDOWS. See the os/user package
+// for a possible alternative.
func Getgroups() ([]int, error) {
gids, e := syscall.Getgroups()
return gids, NewSyscallError("getgroups", e)