1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-11-26 08:49:37 +00:00

Mark WOZs as read-only, with exposition as to why.

This commit is contained in:
Thomas Harte 2020-07-19 00:08:49 -04:00
parent d8b699c869
commit 47f121ee4c

View File

@ -214,5 +214,12 @@ void WOZ::set_tracks(const std::map<Track::Address, std::shared_ptr<Track>> &tra
}
bool WOZ::get_is_read_only() {
return file_.get_is_known_read_only() || is_read_only_ || type_ == Type::WOZ2; // WOZ 2 disks are currently read only.
/*
There is an unintended issue with the disk code that sites above here: it doesn't understand the idea
of multiple addresses mapping to the same track, yet it maintains a cache of track contents. Therefore
if a WOZ is written to, what's written will magically be exactly 1/4 track wide, not affecting its
neighbours. I've made WOZs readonly until I can correct that issue.
*/
return true;
// return file_.get_is_known_read_only() || is_read_only_ || type_ == Type::WOZ2; // WOZ 2 disks are currently read only.
}