fix course sort crashes

This commit is contained in:
Glenn Maynard
2004-06-20 16:54:51 +00:00
parent f15212a563
commit 7634898375
2 changed files with 4 additions and 5 deletions
+2 -2
View File
@@ -1008,9 +1008,9 @@ void Course::UpdateCourseStats( StepsType st )
return;
}
Trail* pTrail = GetTrail( st, DIFFICULTY_MEDIUM );
const Trail* pTrail = GetTrail( st, DIFFICULTY_MEDIUM );
m_SortOrder_TotalDifficulty += pTrail->GetTotalMeter();
m_SortOrder_TotalDifficulty += pTrail != NULL? pTrail->GetTotalMeter():0;
// OPTIMIZATION: Ranking info isn't dependant on style, so
// call it sparingly. Its handled on startup and when