Skip to main content

Name

control_shutdown_ex — Invoked when shutdown occurs

Synopsis

#include "hooks/core/control_shutdown_ex.h"

| void **core_control_shutdown_ex** ( | closure, |   | |   | die, |   | |   | ret, |   | |   | file, |   | |   | lineno); |   |

void * <var class="pdparam">closure</var>; int <var class="pdparam">die</var>; int <var class="pdparam">ret</var>; const char * <var class="pdparam">file</var>; int <var class="pdparam">lineno</var>;

Description

This hook is invoked when an instance shutdown occurs. This typically occurs when a shutdown command is issued over ec_console. However, this may also be called in the event of an unexpected crash.

The parameters provide information on why the instance is being shut down. If die is non-zero then it contains the signal that triggered the shut down. The ret contains the command status that will be returned to the operating system. file and lineno contain the call site that triggered the shut down.

Parameters

closure

The closure.

die

When this parameter is non-zero then it contains the signal that triggered the shut down.

ret

The command status that will be returned to the operating system.

lineno

The call site that triggered the shut down.

Return Values

This function returns void.

Threading

This hook will be called in the Scheduler thread.

See Also

Was this page helpful?