DOS SYSTEM FILE TABLE
Posted on 1998-09-16
I want to write a utility to trace the current files in use during a process.
The way I plan to do this is :
1 make a call to INT 21,52 to get at the DOS INVARS
2 get to byte offset 04 which is a pointer to SFT
3 construct a linked list with SFT byte offset 00 which points to the next SFT
4 get the file count from SFT byte offset 04
at this point I get stuck. the documentation I have on "undocumented DOS" says that there are 59 bytes from SFT byte offset 06 for the file descriptor table which you have to repeate <file count> times, once for each file.
The offset 20 from the file descriptor table start (SFT offset 06) is where the file name is in FCB format (11 bytes). This documentation is for DOS 4.0+.
What I want to know is am i heading the correct way?
Is the SFT structure for DOS 6.22 and above the same as DOS 4.0?