From 79002d69628972fd5ba45e1d8b4d96db917ffb99 Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Mon, 30 Apr 2018 22:07:54 -0400 Subject: [PATCH] Adds an additional assert. --- Storage/Disk/Drive.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Storage/Disk/Drive.cpp b/Storage/Disk/Drive.cpp index 4fcf69108..5ef0dac5f 100644 --- a/Storage/Disk/Drive.cpp +++ b/Storage/Disk/Drive.cpp @@ -163,6 +163,7 @@ void Drive::get_next_event(const Time &duration_already_passed) { // divide interval, which is in terms of a single rotation of the disk, by rotation speed to // convert it into revolutions per second; this is achieved by multiplying by rotational_multiplier_ assert(current_event_.length <= Time(1) && current_event_.length >= Time(0)); + assert(current_event_.length > duration_already_passed); Time interval = (current_event_.length - duration_already_passed) * rotational_multiplier_; set_next_event_time_interval(interval); }