From e38b822303efccf27ab6cfbb50993dfa743c5219 Mon Sep 17 00:00:00 2001 From: Evgeniy Meshcheryakov Date: Wed, 27 Jul 2022 12:30:54 +0300 Subject: [PATCH] Fix crash in scenario information window if campaign has no difficulty settings --- client/lobby/CBonusSelection.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/client/lobby/CBonusSelection.cpp b/client/lobby/CBonusSelection.cpp index 78b62736b..f369c04af 100644 --- a/client/lobby/CBonusSelection.cpp +++ b/client/lobby/CBonusSelection.cpp @@ -360,8 +360,10 @@ void CBonusSelection::updateAfterStateChange() buttonStart->disable(); buttonRestart->enable(); buttonBack->block(false); - buttonDifficultyLeft->disable(); - buttonDifficultyRight->disable(); + if(buttonDifficultyLeft) + buttonDifficultyLeft->disable(); + if(buttonDifficultyRight) + buttonDifficultyRight->disable(); } if(CSH->campaignBonus == -1) {