Koolstar42
Experienced Member
I noticed that my CP/M 2.2 implementation would sometimes crash after completion of certain programs. Examples are Turbo pascal, toolworks C/80, Digital Link v1.31.
I have determined that this is caused by said applications overwriting the first 6 bytes of BDOS, which contains the serial number. After reloading the CCP it checks this serial number and halts when it is incorrect. I could fix this easily by reloading the first sector of BDOS too. Basically pretending that the CCP is 1 sector longer. But I feel this should not be necessary. Apparently top of TPA is derived from the BDOS call in the base page address 0005h. Is this just bad behavior of the applications or am I missing something?
I have determined that this is caused by said applications overwriting the first 6 bytes of BDOS, which contains the serial number. After reloading the CCP it checks this serial number and halts when it is incorrect. I could fix this easily by reloading the first sector of BDOS too. Basically pretending that the CCP is 1 sector longer. But I feel this should not be necessary. Apparently top of TPA is derived from the BDOS call in the base page address 0005h. Is this just bad behavior of the applications or am I missing something?