Mail Archives: djgpp/1997/06/10/14:21:53
> with spawn, system, exec or the like, very little checking is done to make
> sure the program is an appropriate executable.
This comes up every once in a while. DOS does its own checking to
see if something is an EXE file or not. If not, it assumes a COM
file. No way to check really. Try renaming files to .com and running
them from command prompt and see what happens.
> Isn't protected mode supposed to
> prevent this?)
You probably weren't in protected mode when it crashed. The switch only
occurs after you exe loads up.
> I realize this is rather a case of "Don't do that, then", but it would sure
> be nice if bogus binaries were checked for, or at *least* if this problem
> could be documented better. Hopefully others can avoid a similar difficulty.
Every system has problems similar to this. The GCC make utility for
cross-compiling isn't that smart. HPUX typically tries to run
my dos exes natively, and passes them to bourne shell, which then
dies miserably.
- Raw text -