Fix crash with empty ScheduledDowntime 'ranges' attribute

fixes #11158
This commit is contained in:
Michael Friedrich 2016-04-22 11:00:21 +02:00 committed by Gunnar Beutner
parent 4558488d97
commit 418636f7da

View File

@ -131,6 +131,9 @@ std::pair<double, double> ScheduledDowntime::FindNextSegment(void)
Dictionary::Ptr ranges = GetRanges();
if (!ranges)
return std::make_pair(0, 0);
Array::Ptr segments = new Array();
Dictionary::Ptr bestSegment;