From 5e073dfc00ad995b0f51fc2c7ced7c2393555a0f Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Tue, 2 Sep 2003 20:25:00 +0000 Subject: [PATCH] Fix crash if there are two steps with Challenge difficulty --- stepmania/src/Song.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stepmania/src/Song.cpp b/stepmania/src/Song.cpp index 2635d5f0a6..d68bbb3d78 100644 --- a/stepmania/src/Song.cpp +++ b/stepmania/src/Song.cpp @@ -796,7 +796,7 @@ void Song::TidyUpData() { Steps* pSteps = vSteps[k]; - Difficulty dc2 = (Difficulty)(dc+1); + Difficulty dc2 = min( (Difficulty)(dc+1), DIFFICULTY_CHALLENGE ); pSteps->SetDifficulty( dc2 ); } }