From f1db9559f93545e97793fb662a60a1ee81fd9ae1 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 14 May 2016 01:14:32 -0400 Subject: [PATCH] Range: Corrected assert for open ranges --- src/Range.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Range.cpp b/src/Range.cpp index 5eaee6c6..68d10f38 100644 --- a/src/Range.cpp +++ b/src/Range.cpp @@ -286,7 +286,7 @@ std::vector Range::subtract (const Range& other) const // If the range is open, use 'now' as the end. time_t Range::total () const { - assert (end >= start); + assert (! is_ended () || end >= start); if (is_ended ()) return Datetime (end) - Datetime (start);