register-exit-function!

[procedure] register-exit-function! proc

Bigloo, STklos: arrange proc to be called just before the execution of the program terminates by exit call. A numerical exit code is passed to proc.