Mail Archives: djgpp-workers/1998/07/12/12:24:57
On Fri, 10 Jul 1998, Martin Str|mberg wrote:
> > If you mean to access data in segment other than DS, then you can't do
> > that in GDB directly. You need to call a C function like dosmemget
> > for that, assuming that it's linked into the debugged program.
> >
> > The same goes for selector data: call the appropriate C function from
> > the GDB prompt.
>
> Hmm. But how do I get the base address as that function expects an
> argument of type 'int *'?
The easiest way is to write a wrapper that returns the value pointed
by the int *, and link it into your program.
> Another question, suppose ds's base address is 0x1000 and edx is
> 0x100, is the address edx points to 0x100 or 0x1100?
AFAIK, the linear address is 0x100, the logical address is 0x1100.
- Raw text -