1
0
mirror of https://github.com/pevans/erc-c.git synced 2024-11-27 20:51:17 +00:00

We can't have a negative track pos; zero is the lowest

This commit is contained in:
Peter Evans 2017-12-14 22:46:50 -06:00
parent a82348ff9a
commit f629b350fa

View File

@ -66,8 +66,8 @@ apple2dd_step(apple2dd *drive, int steps)
if (drive->track_pos > MAX_DRIVE_STEPS) { if (drive->track_pos > MAX_DRIVE_STEPS) {
drive->track_pos = MAX_DRIVE_STEPS; drive->track_pos = MAX_DRIVE_STEPS;
} else if (drive->track_pos < -MAX_DRIVE_STEPS) { } else if (drive->track_pos < 0) {
drive->track_pos = -MAX_DRIVE_STEPS; drive->track_pos = 0;
} }
} }