Topic : The ATARI Compendium
Author : Scott Sanders / JAY Software
Version : 1.25 (20/6/2003)
Subject : Documentation
Nodes : 1117
Index Size : 32614
HCP-Version : 6
Compiled on : Atari
@charset : UTF-8
@lang : en
@default :
@help : %About
@options : +g -i -t4 +y +z
@width : 100
View Ref-FileSync()Shutdown() GEMDOSSyntaxLONG Shutdown( mode )
WORD mode;
Function Shutdown() kills all processes, syncs filesystems then halts
or reboots the system.
Opcode 337 (0x0151)
Availability This function is available under all MiNTversions integrated
with MultiTOS.
Parametres If mode is zero, the system will shutdown then enter a halted
condition. On mode equal to 1, the system will reboot the
machine after shutting everything down.
All other values of mode are reserved for future definition.
Binding move.w mode,-(sp)
move.w #$0151,-(sp)
trap #1
addq.l #4,sp
Return Value Shutdown() returns a negative GEMDOS error code, if failed.
On success this call obviously never returns.
Caveats All current versions of MiNT (including 1.15.x) contain a bug
that causes the system to crash, if you call Shutdown() while
both GEMAES and virtual console daemon are present.
Comments You need root privileges to shut the system down.
See Also Sync()