From d94315ee3f320c4edcc562c642dabcd63ecceebd Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 27 May 2022 20:03:30 +0900 Subject: [PATCH] Fix potential crash from unsafe drawable mutation in scoreboard update code --- .../Screens/OnlinePlay/Match/Components/MatchLeaderboard.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game/Screens/OnlinePlay/Match/Components/MatchLeaderboard.cs b/osu.Game/Screens/OnlinePlay/Match/Components/MatchLeaderboard.cs index ea7de917e2..b92c197f5a 100644 --- a/osu.Game/Screens/OnlinePlay/Match/Components/MatchLeaderboard.cs +++ b/osu.Game/Screens/OnlinePlay/Match/Components/MatchLeaderboard.cs @@ -38,13 +38,13 @@ namespace osu.Game.Screens.OnlinePlay.Match.Components var req = new GetRoomLeaderboardRequest(roomId.Value ?? 0); - req.Success += r => + req.Success += r => Schedule(() => { if (cancellationToken.IsCancellationRequested) return; SetScores(r.Leaderboard, r.UserScore); - }; + }); return req; }