Mail Archives: djgpp/1995/04/27/11:16:04
> and I got: i = 0x38
>
> I think this is an index in the descriptor table which includes
> among other things base addresses of the segments and their length.
Yes.
> u_short i = _go32_conventional_mem_selector();
> printf("value = %x\n", *((int *)(int)i ));
> }
>
> and I got:
> Segmentation violation in pointer 0x00000038 at d8:11ca ...
>
> I think this area of memory is protected but is there any
> way to access the descriptor table to see what is real segment's
> base address and its length ?
Use functions from <sys/farptr.h>. You might find it useful to read
Chapter 18 of the DJGPP FAQ list (available as faq100.zip from the
same place you get DJGPP). It discusses these issues at length.
- Raw text -