1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-14 19:03:22 +08:00

Add comment regarding deadlock avoidance

This commit is contained in:
Dean Herbert 2022-05-31 12:24:44 +09:00
parent c892aed797
commit 477e520766

View File

@ -83,6 +83,7 @@ namespace osu.Game.Tests.Visual.OnlinePlay
#pragma warning disable RS0030
// We can't GetResultSafely() here (will fail with "Can't use GetResultSafely from inside an async operation."), but Wait is safe enough due to
// the task being a TaskCompletionSource.
// Importantly, this doesn't deadlock because of the scheduler call above running inline where feasible (see the `false` argument).
return tcs.Task.Result;
#pragma warning restore RS0030
};