>... If the user
>presses ctrl-alt-del the system will reboot immediately and may trash your
>filesystems (for example when performing an update of the system).
Quite apart from the desirability of having an init with pid=1,
it is easy to avoid reboot on ctrl-alt-del:
(i) Make ctrl-alt-del produce some signal. Put this in a shell script:
loadkeys << EOF
control alt keycode 83 = KeyboardSignal
control alt keycode 111 = KeyboardSignal
EOF
(ii) Let your favourite process catch it:
ioctl(fd, KDSIGACCEPT, (long) SIGHUP);
Andries