Hi!
19-Июн-2004 09:45 [EMAIL PROTECTED] (Eduardo Casino) wrote to
[EMAIL PROTECTED]:
>> EC> * APPEND is now a COM file (smaller), as suggested by Eric, but
>> EC> it keeps the EXE extension.
>> Is it .COM file renamed to .EXE or this is .EXE file with header, as in
>> .COM? If first, then I against this, because .COM format is bad for TSR
>> (which will loaded into UMB by LH command). If you wish to remain in ".COM
>> mode", you may _convert_ .COM into .EXE (for example, with help of my
>> COM2EXE).
EC> It is .COM renamed to .EXE.
Renaming .COM to .EXE gives nothing useful, except misinforming user.
EC> I'm a bit new to this so, will you be so kind of explaining why is it bad?
EC> I've loaded it into UMB with LH and it seems to work.
Unlike .COM, .EXE files have header, where sayed how much of memory
should be allocated for program when it loaded. This allows for LH to load
program into more appropriate UMB, not into the largest. For .COM files
always should be selected largest UMB, because it (by specification)
requires up to 64k of memory available at start.
Secondly, DOS may load .COM file into lesser (than 64k) UMB, if there
are no larger UMB, but, if program doesn't check that SP is above its your
required memory, then it will work wrong and/or overwrites MCB of next
block. For example, I know one (very useful program!), which works
incorrectly, when loaded by LH and there are low of UMBs. With .EXE, this
will never happen.
This is reason, why I wrote COM2EXE and convert CTMOUSE.COM into .EXE.
This adds only 32 bytes of header, so, overhead is small, but safety and
convenience for user is much increased. You may get my COM2EXE from
CuteMouse package or wrote your own COM2EXE utility. When converting .COM
into .EXE, my utility says in .EXE header, than program requires 64k of
memory, unless you use -s option, which specifies how much of space should
be allocated for data and stack areas. For CTMOUSE I specify 512 bytes,
which includes zero data area and 512 bytes of stack.
Warning: unlike .COM, for .EXE DOS doesn't places zero on top of stack,
so, you can't end .EXE program (plain .EXE or converted from .COM to .EXE)
by RET instruction, only by INT20 or INT21/4C.
-------------------------------------------------------
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
_______________________________________________
Freedos-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freedos-devel