Drop restart_pre/restart_post
By design, restart is hard coded to run stop followed by start along with all of the pre/post functions associated with them. Restart doesn't need its own pre/post functions since it is possible to make any function in an init script behave differently for a restart command by testing against the RC_CMD environment variable.
This commit is contained in:
@@ -447,11 +447,6 @@ depend()
|
||||
need ${_need}
|
||||
}
|
||||
|
||||
restart_pre() {
|
||||
# Verify a config and abort the restart in case it's not valid
|
||||
...
|
||||
}
|
||||
|
||||
# This function does any pre-start setup. If it fails, the service will
|
||||
# not be started.
|
||||
# If you need this function to behave differently for a restart command,
|
||||
|
Reference in New Issue
Block a user