mirror of
https://github.com/rwinkhart/sys.git
synced 2026-08-31 22:36:44 -04:00
unix: make Prlimit public
glibc has a wrapper for it, so why shouldn't we? Change-Id: I5c6e24c8e567e0198ea679f0be33e2eff056d5ed Reviewed-on: https://go-review.googlesource.com/c/sys/+/332029 Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com> Reviewed-by: Ian Lance Taylor <iant@golang.org> Trust: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
committed by
Brad Fitzpatrick
parent
d867a43fc9
commit
30e4713e60
@@ -1211,7 +1211,7 @@ func PivotRoot(newroot string, putold string) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func prlimit(pid int, resource int, newlimit *Rlimit, old *Rlimit) (err error) {
|
||||
func Prlimit(pid int, resource int, newlimit *Rlimit, old *Rlimit) (err error) {
|
||||
_, _, e1 := RawSyscall6(SYS_PRLIMIT64, uintptr(pid), uintptr(resource), uintptr(unsafe.Pointer(newlimit)), uintptr(unsafe.Pointer(old)), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
|
||||
Reference in New Issue
Block a user