Enable building on unsupported systems

This commit is contained in:
Daniel
2020-07-22 11:13:57 +02:00
parent 3b6cd55d51
commit 084c194da3
4 changed files with 74 additions and 1 deletions

View File

@@ -0,0 +1,28 @@
//+build !windows,!linux
package process
// IsUser returns whether the process is run by a normal user.
func (p *Process) IsUser() bool {
return true
}
// IsAdmin returns whether the process is run by an admin user.
func (p *Process) IsAdmin() bool {
return false
}
// IsSystem returns whether the process is run by the operating system.
func (p *Process) IsSystem() bool {
return false
}
// IsKernel returns whether the process is the Kernel.
func (p *Process) IsKernel() bool {
return p.Pid == 0
}
// specialOSInit does special OS specific Process initialization.
func (p *Process) specialOSInit() {
}