mirror of
https://github.com/criyle/go-sandbox.git
synced 2025-11-04 14:49:53 +08:00
13 lines
286 B
Go
13 lines
286 B
Go
package forkexec
|
|
|
|
import _ "unsafe" // to use go:linkname
|
|
|
|
//go:linkname beforeFork syscall.runtime_BeforeFork
|
|
func beforeFork()
|
|
|
|
//go:linkname afterFork syscall.runtime_AfterFork
|
|
func afterFork()
|
|
|
|
//go:linkname afterForkInChild syscall.runtime_AfterForkInChild
|
|
func afterForkInChild()
|