|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
List of lists code example
Does anybody have a working example code using dos int 52h to know all
program in memory in dos? I´ve been trying to use it unsucesfully for quite a time |
|
#2
|
|||
|
|||
|
List of lists code example
Everytime I try to search for "how mem.exe works" or something like
that I end up with "you need to use int21h/52h to get list-of-lists and walk through the MCB chain" Well, I tried this: #include "dos.h" #include "mem.h" struct mcb { char flag; unsigned owner; unsigned length; char junk[3]; char name[8]; }; void main(void) { union REGS inregs, outregs; struct SREGS sregs; struct mcb mcb; unsigned char far *p, *addr; inregs.h.al = 0x00; inregs.h.ah = 0x52; intdosx(&inregs, &outregs, &sregs); p = MK_FP(_DS, _BX-2); memcpy(&mcb, p, sizeof(mcb)); } Sorry if this looks absurd someway, but I´ve tried A LT of things before that Watching mcb var never returns the 'M' signature I would see if the first MCB was pointed correctly I tried using *p, $p, p in every situations (sorry about it, but i am desesperated already) What am I doing wrong? |
|
#3
|
|||
|
|||
|
List of lists code example
gerotica wrote:
Everytime I try to search for "how mem.exe works" or something like that I end up with "you need to use int21h/52h to get list-of-lists and walk through the MCB chain" Well, I tried this: Why not get source code for FreeDS' MEM? -- Robert Riebisch Bitte NUR in der Newsgroup antworten! Please reply to the Newsgroup NLY! |
![]() |
| Viewing: Web Development Archives > FAQs > MS DOS > List of lists code example |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|