syscall

package
Version: v0.0.0-...-b957d1f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 28, 2017 License: BSD-3-Clause Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EINVAL = Errno(iota + 1)
	EISDIR
	ENOTDIR
	ENAMETOOLONG
	EPIPE
)
View Source
const (
	O_RDONLY = 1 << iota
	O_WRONLY
	O_RDWR
	O_CREAT
	O_APPEND
	O_TRUNC
	O_EXCL
	O_SYNC
)
View Source
const (
	EPOLLIN = 1 << iota
	EPOLLPRI
	EPOLLOUT
	EPOLLERR
	EPOLLHUP
)
View Source
const ImplementsGetwd = false

Variables

View Source
var (
	Stdin  = 0
	Stdout = 1
	Stderr = 2
)

Functions

func Chdir

func Chdir(path string) error

func Clearenv

func Clearenv()

func Environ

func Environ() []string

func Exit

func Exit(code int)

func Fchdir

func Fchdir(fd int) error

func Getegid

func Getegid() int

func Getenv

func Getenv(s string) (string, bool)

func Geteuid

func Geteuid() int

func Getgid

func Getgid() int

func Getgroups

func Getgroups() ([]int, error)

func Getpid

func Getpid() int

func Getppid

func Getppid() int

func Getuid

func Getuid() int

func Getwd

func Getwd() (dir string, err error)

func Mkdir

func Mkdir(path string, perm uint32) error

func Read

func Read(fd int, b []byte) (n int, err error)

Read is currently unsupported.

func Setenv

func Setenv(key, value string) error

func Unsetenv

func Unsetenv(key string) error

func Write

func Write(fd int, b []byte) (n int, err error)

Write writes the contents of b to fd and returns the number of bytes written or an error.

If fd is Stdout, b is written with WriteConsole.

func WriteConsole

func WriteConsole(b []byte) int

WriteConsole writes b to the Xen console and returns the number of bytes written.

Types

type Errno

type Errno uintptr

An Errno is an unsigned number describing an error condition. It implements the error interface. The zero Errno is by convention a non-error, so code to convert from Errno to error should use:

err = nil
if errno != 0 {
	err = errno
}

func (Errno) Error

func (e Errno) Error() string

type Stat_t

type Stat_t struct {
	Dev uint64
	Ino uint64
}

type SysProcAttr

type SysProcAttr struct{}

type Timespec

type Timespec struct {
	Sec  int64
	Nsec int64
}

type Timeval

type Timeval struct {
	Sec  int64
	Usec int64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL