1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-07-07 08:28:57 +00:00

Corrected reading of the track size table for extended disks. My first extended disk has now loaded.

This commit is contained in:
Thomas Harte 2017-08-07 11:38:19 -04:00
parent d951c8c1c2
commit 895a3cbf24

View File

@ -27,6 +27,8 @@ CPCDSK::CPCDSK(const char *file_name) :
head_count_ = (unsigned int)fgetc(file_);
if(is_extended_) {
// Skip two unused bytes and grab the track size table.
fseek(file_, 2, SEEK_CUR);
for(unsigned int c = 0; c < head_position_count_ * head_count_; c++) {
track_sizes_.push_back((size_t)(fgetc(file_) << 8));
}