Chapter
1
I
System
Calls
Abort
Terminate
Program
Function Call
OOH
Terminates
a
program. This function is called by Interrupt
20H, and performs the same processing.
The following exit addresses are restored from the specified
offsets in the Program Segment Prefix:
Program terminate
Critical error
CONTROL-C
OAH
OEH
12H
All file buffers are written to disk. Be sure
to
close all
files that have been changed in length before calling this
function. If a changed file is not closed, its length will
not be recorded correctly in the disk directory. See Func-
tion Call 10H
for
a
description
of
the Close File call.
Entry Conditions:
AH
=
OOH
CS
=
segment address
of
the
Program Segment Prefix
Macro Definition:
terminate-program macro
xor ah,ah
int
21
H
endm
Example:
;CS
must
be
equal
to
PSP
values given
at
program start
;(E5
and
DS
values)
mov
ah,0
int
21H
;There are
no
returns from this interrupt
32