Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddExitFunc ¶
func AddExitFunc(f func()) func()
AddExitFunc adds a given function to the list of functions that should return at exit. Its return value is the same function, wrapped in a sync.Once. If for some reason you want to call the handler before program exit, you can call the returned function.
func RunExitFuncs ¶
func RunExitFuncs()
RunExitFuncs runs all the registered exit funcs. This function should be called at the end of main(), or whenever the program is calling os.Exit().
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.