Mail Archives: djgpp/1997/06/01/13:09:42
On Sun, 1 Jun 1997, Andrew Crabtree wrote:
> It is located in malloc (one that I haven't touched), on a line like
> follows
>
> movl (%edx),%eax
>
> The crash shows it with a rediculously high edx, inside gdb
> it is much more reasonable (about 0x4000)
Very strange indeed. But a bit of debugging there might reveal the
reason for this.
> I still don't understand why bash works but command.com doesn't.
> I assume (probably incorrectly) that they exec programs in the same way.
Your assumption is indeed wrong. Since Bash is a DJGPP program, it
invokes other DJGPP programs in a way that's a bit different than
COMMAND.COM. And if you called HELLO from Bash when both `hello' (raw
COFF file) and `hello.exe' were in the current directory, Bash would
invoke `hello', much in the same way as gdb loads the debuggee.
Another difference is that when Bash runs HELLO, you get netsed DPMI
programs, which also changes things (selectors etc.)
- Raw text -