Closed lydon42 closed 1 year ago
There is currently a systematic problem with the image attach/detach functions.
Currently we have a d81attach0 and d81attach1 function call, to attach an image to either drive 0 or 1. Then there is a d81detach which will detach both images at once. Both calls will update the internal processdescriptor to reflect the image currently attached.
There is no call to just detach one image, which in my eyes is missing. Because of that BASIC MOUNT will just use pokes to unmount the image on one drive, which is then not reflected in the display of the FREEZER. In the same way it is not actually detaching the image, but it is attaching the internal drive. For this there is also no call. And so there is also no update to processdescriptor.
The proposal is to:
This way all old calls will stay compatible.
This fixes the size check close file problem, But I keep it open, because I would like to reorganize the hyppo mount functions and also provide a single drive unmount.
Working in 620-hyppo-dos13
Removing enhancement part from bug part for clarity. Work continues in #628
A d64 image is not attached, as the dos_d81check routine does not check it's size correctly.
In addition the whole "which image is it" is done double in d81check and d81attach0 and d81attach1. So it would be reasonable to store the detection result of d81check, and not check sizes again in attach to set the flags correctly.