Mail Archives: djgpp-workers/2000/02/18/16:12:53
At 15:04 18/02/00 -0300, you wrote:
>Pierre Muller wrote:
>
>> Hello,
>>
>> I wrote the Run Time Library of the Free Pascal port to DJGPP system.
>> As such, I changed crt0.S to allow starting a program without any use of
the
>> C library.
>>
>> Due to internal problems, I disabled the multiblock feature in the
>> startup code.
>> Thus our RTL uses Unixy sbrk with selector base changes.
>
>How it affects? is this problem found only when using Unixy sbrk?
I don't know,
it really seems that its only when the base is changed!
>> Recently, we got more and more problems with our IDE
>> (a freeware equivalent of the Borland editor BP) under Windows.
>> These crashes allways appeared in the VMOUSE VXD and completely crashed the
>> computer!
>
>I have a TV application + Win95 system that have this problem (ramdonly).
But is on
>exit.
But is the mouse already disabled ?
Any other code using the alias could have the same bug...
doesn't exceptn.S also use djgpp_ds_alias for the keyboard real mode
stuff (the one that catches Crtl-C) ??
I first sent this message to Eli,
but he told me to send it to the list and to Charles Sandmann
But I forgot this, I did it right now!
>> These errors were even more frequent on Win98 and Win 2000 !!
>> After quite long and hard debugging, I finally realized that
>> there is a major bug in the startup code:
>>
>> when the function 0x503 of DPMI is called,
>> only the cs and ds selector are updated in the 16 byte sbrk16.asm code.
>> The djgpp_ds_alias selector (that is used for the RMCB
>> to avoid problems with fake exceptions like Crtl-C) is updated
>> later in the 32 bit code... but its updated after the
>> interrupts are reenabled !!!
>
>Ugh!
>
>> If the mouse callback is called in the interval between the 0x503
>> function call and the update
>> of the alias selector base address => you get the crash!!
>>
>> I include here a diff to version 2.03 of crt0.S file that also fixes the
>> problem for the C library!
>> Could someone please test this with RHIDE
>> because the recent problem about linking could be due to that fact
>> if (and I don't know if this is true) the linker is called internally !
>
>You mean it could be because the RHIDE's RMCB is called during ld startup?
Its a possibility but I have never really understood how
other DJGPP exes are run from a DJGPP exe !
- Raw text -