LegacyTimePeriod::ProcessTimeRangeRaw(): support ranges across midnight

refs #5261
This commit is contained in:
Alexander A. Klimov 2019-03-12 15:26:08 +01:00 committed by Michael Friedrich
parent b7279597d9
commit ffd736f56f
1 changed files with 1 additions and 1 deletions

View File

@ -342,7 +342,7 @@ void LegacyTimePeriod::ProcessTimeRangeRaw(const String& timerange, tm *referenc
if (begin->tm_hour * 3600 + begin->tm_min * 60 + begin->tm_sec >=
end->tm_hour * 3600 + end->tm_min * 60 + end->tm_sec)
BOOST_THROW_EXCEPTION(std::invalid_argument("Time period segment ends before it begins"));
end->tm_hour += 24;
}
Dictionary::Ptr LegacyTimePeriod::ProcessTimeRange(const String& timestamp, tm *reference)