From 8302aa9b4a7a93ed86be6b14a778087e99b2ed5b Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Mon, 29 Sep 2003 04:22:59 +0000 Subject: [PATCH] Fix "exit" row --- stepmania/src/ScreenOptionsMaster.cpp | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/stepmania/src/ScreenOptionsMaster.cpp b/stepmania/src/ScreenOptionsMaster.cpp index d6d5b9c0cc..e56d267034 100644 --- a/stepmania/src/ScreenOptionsMaster.cpp +++ b/stepmania/src/ScreenOptionsMaster.cpp @@ -472,13 +472,16 @@ void ScreenOptionsMaster::ExportOptions() m_NextScreen = ""; const int row = this->GetCurrentRow(); - const OptionRowHandler &hand = OptionRowHandlers[row]; - if( hand.type == ROW_LIST ) + if( row < (int) OptionRowHandlers.size() ) /* might be on "exit" */ { - const int sel = m_iSelectedOption[0][row]; - const ModeChoice &mc = hand.ListEntries[sel]; - if( mc.m_sScreen != "" ) - m_NextScreen = mc.m_sScreen; + const OptionRowHandler &hand = OptionRowHandlers[row]; + if( hand.type == ROW_LIST ) + { + const int sel = m_iSelectedOption[0][row]; + const ModeChoice &mc = hand.ListEntries[sel]; + if( mc.m_sScreen != "" ) + m_NextScreen = mc.m_sScreen; + } } // NEXT_SCREEN(GAMESTATE->m_PlayMode) );