home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
World_Of_Computer_Software-02-386-Vol-2of3.iso
/
b
/
bootp.zip
/
CHKSTKS.ASM
< prev
next >
Wrap
Assembly Source File
|
1987-04-16
|
512b
|
32 lines
include masmdefs.hsm
include model.hsm
codedef CHKSTK
datadef
cstart CHKSTK
cproc _chkstk
if FUNC_L
pop cx ; get return offset
pop dx ; get return segment
else
pop cx ; get return offset
endif
mov bx,sp
sub bx,ax ; new position
mov sp,bx ; set new stack pointer
if FUNC_L
push dx ; push segment
push cx ; push offset
ret ; far return to dx:cx
else
jmp cx ; return to cx
endif
cendp _chkstk
cend CHKSTK
end