Updated: April 19, 2023 |
Reboot the system
#include <sys/sysmgr.h> int sysmgr_reboot( void );
libc
Use the -l c option to qcc to link against this library. This library is usually included automatically.
The sysmgr_reboot() function reboots the calling computer. In order to successfully call this function, your process must have the PROCMGR_AID_REBOOT ability enabled. For more information, see procmgr_ability().
The sysmgr_reboot() function doesn't return if successful. If an error occurs, it returns -1 and sets errno.
Safety: | |
---|---|
Cancellation point | No |
Interrupt handler | No |
Signal handler | Yes |
Thread | Yes |