China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-08-01 02:20
中国DOS联盟论坛 » DOS开发编程 & 发展交流 (开发室) » Question about TSR programs View 742 Replies 1
Original Poster Posted 2003-09-17 00:00 ·  中国 陕西 渭南 电信
初级用户
Credits 107
Posts 1
Joined 2003-09-17 00:00
22-year member
UID 9949
Gender Male
Status Offline
I'm writing a TSR program. It can already stay resident normally, but I don't know how to make it exit and free the memory. The exit routine I wrote now can restore the interrupt, but the program is still there, and if I run it again it will use another location.
I'm a newbie, and I really don't understand memory management and allocation under DOS, so I don't know what to do. Experts, please give me some advice! Thanks in advance!!!
Floor 2 Posted 2003-09-19 00:00 ·  中国 湖北 武汉 鹏博士宽带
初级用户
Credits 77
Posts 11
Joined 2003-09-17 00:00
22-year member
UID 9925
Gender Male
Status Offline
Record the memory segment of your own TSR code, then use one of the functions in int21 (can't remember which one) to release it.
Forum Jump: