> extraction the version wanted out of > > mov AH, 30h > int 21h > cmp ax, ABCD <<< this is the version wanted > jne exit_program > > is not "heuristic". So simple. > > It returns exactly the version required to the calling program. if this > request > is posted in the proper form. > which is true for all MSDOS programs. > no more. no less.
Unfortunately, not all programs are that simple. Many of the MS utility programs are looking for a very specific version of DOS, but some are looking for "categories". On some of my programs, e.g., I have a "GetDOSVersion" subroutine that simply returns the DOS version value to the caller so the INT 21.30 call is not immediately followed by a CMP AX/JNE. It could also be that the version is not "hard-coded" (ABCD) but is store in a register, or uses something other than JNE, or all kind of other possibilities. Some programs test the major & minor version numbers separately for various reasons. As you stated earlier, some programs need to look for "categories" (like do one thing for DOS < 3.30 and do something else for DOS <= 5.xx and yet something else for DOS >= 6. The "heuristic" method wouldn't work on anything like that. Also, there are lots of "regular" programs (not utilities from MS) that require special version numbers for various reasons. E.g., the SETVER programs that comes with MS-DOS 7.1 has the following setup by default: KERNEL.EXE 5.00 NETX.COM 5.00 NETX.EXE 5.00 NET5.COM 5.00 BNETX.COM 5.00 BNETX.EXE 5.00 EMSNETX.EXE 5.00 EMSNET5.EXE 5.00 XMSNETX.EXE 5.00 XMSNET5.EXE 5.00 DOSOAD.SYS 5.00 REDIR50.EXE 5.00 REDIR5.EXE 5.00 REDIRALL.EXE 5.00 REDIRNP4.EXE 5.00 RECOVER.EXE 5.00 LMSETUP.EXE 5.00 STACKER.COM 5.00 NCACHE.EXE 5.00 NCACHE2.EXE 5.00 IBMCACHE.SYS 5.00 XTRADRV.SYS 5.00 2XON.COM 5.00 WINWORD.EXE 4.10 EXCEL.EXE 4.10 LL3.EXE 4.01 REDIR4.EXE 4.00 REDIR40.EXE 4.00 MSREDIR.EXE 4.00 WIN200.BIN 3.40 METRO.EXE 3.31 DISKFIX.EXE 1.00 10NET.COM 6.20 DBLSPACE.EXE 6.20 BASIC.COM 7.10 BASICA.COM 7.10 DISKCOMP.EXE 7.10 EXTDISK.SYS 7.10 GRAPHICS.COM 7.10 MODE_DOS.COM 7.10 REPLACE.EXE 7.10 SCPLUS.EXE 7.10 SCSIC710.SYS 7.10 TREE.COM 7.10 VDISK.SYS 7.10 RESTORE.EXE 6.22 BACKUP.COM 6.22 DISKCOMP.COM 6.22 SHARE.EXE 7.00 APPEND.EXE 5.00 PRINT.EXE 6.22 FASTOPEN.EXE 6.22 I don't even know what all those programs are, but I do recognize some of them including EXCEL & WINWORD from the old DOS versions of MS Office/Works, which some people still might use. _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel