You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
go-zero/core/proc/shutdown+polyfill.go

29 lines
568 B
Go

//go:build windows
4 years ago
// +build windows
package proc
import "time"
// AddShutdownListener returns fn itself on windows, lets callers call fn on their own.
4 years ago
func AddShutdownListener(fn func()) func() {
return fn
4 years ago
}
// AddWrapUpListener returns fn itself on windows, lets callers call fn on their own.
4 years ago
func AddWrapUpListener(fn func()) func() {
return fn
4 years ago
}
// SetTimeToForceQuit does nothing on windows.
func SetTimeToForceQuit(duration time.Duration) {
4 years ago
}
// Shutdown does nothing on windows.
func Shutdown() {
}
// WrapUp does nothing on windows.
func WrapUp() {
}