Can anyone explane to me how the MS-DOS MCB works? I need some tuts on it or information of how it works. Im sure this is a stupid question and probably simple.
KG.
Help please...
Re: Help please...
MCB is dos's very basic idea of memory management.
if you use dos memory funcs (0x48, etc). alloc a piece of memory. 0x1000h say, sub 1 from its result, this points to the mcb. the mcb contains 3 fields (iirc), one saying (M/Z) if its end of chain/not end of chain, size in paragraphs, and 8 bytes or something for name of what alloced it, and a system field saying if it was alloced by the OS...
basically the mcb just points to the next mcb in memory and tells you if that chunk is or is not free.
if you use dos memory funcs (0x48, etc). alloc a piece of memory. 0x1000h say, sub 1 from its result, this points to the mcb. the mcb contains 3 fields (iirc), one saying (M/Z) if its end of chain/not end of chain, size in paragraphs, and 8 bytes or something for name of what alloced it, and a system field saying if it was alloced by the OS...
basically the mcb just points to the next mcb in memory and tells you if that chunk is or is not free.
-- Stu --