system

package
v0.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2017 License: Apache-2.0, Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Flock

func Flock(fd uintptr, exclusive bool) error

Flock is a wrapper around flock(2).

func Lclearxattrs

func Lclearxattrs(path string) error

Lclearxattrs is a wrapper around Llistxattr and Lremovexattr, which attempts to remove all xattrs from a given file.

func Lgetxattr

func Lgetxattr(path string, name string) ([]byte, error)

Lgetxattr is a wrapper around lgetxattr(2).

func Llistxattr

func Llistxattr(path string) ([]string, error)

Llistxattr is a wrapper around llistxattr(2).

func Lremovexattr

func Lremovexattr(path, name string) error

Lremovexattr is a wrapper around lremovexattr(2).

func Lsetxattr

func Lsetxattr(path, name string, value []byte, flags int) error

Lsetxattr is a wrapper around lsetxattr(2).

func Lutimes

func Lutimes(path string, atime, mtime time.Time) error

Lutimes is a wrapper around utimensat(2), with the AT_SYMLINK_NOFOLLOW flag set, to allow changing the time of a symlink rather than the file it points to.

func Majordev

func Majordev(device Dev_t) uint64

Majordev returns the major device number given a dev_t, similar to major(3).

func Minordev

func Minordev(device Dev_t) uint64

Minordev returns the minor device number given a dev_t, similar to minor(3).

func Mknod

func Mknod(path string, mode os.FileMode, dev Dev_t) error

Mknod is a wrapper around mknod(2).

func Tarmode

func Tarmode(typeflag byte) uint32

Tarmode takes a Typeflag (from a tar.Header for example) and returns the corresponding os.Filemode bit. Unknown typeflags are treated like regular files.

func Unflock

func Unflock(fd uintptr) error

Unflock is a wrapper around flock(2).

func Unlink(path string) error

Unlink is a wrapper around unlink(2).

Types

type Dev_t

type Dev_t uint64

Dev_t represents a dev_t structure.

func Makedev

func Makedev(major, minor uint64) Dev_t

Makedev produces a dev_t from the individual major and minor numbers, similar to makedev(3).

Jump to

Keyboard shortcuts

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