1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 05:27:23 +08:00

Fix locking on incorrect object

Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
This commit is contained in:
Dan Balasescu 2021-01-21 12:45:44 +09:00 committed by GitHub
parent 6b139d4cf3
commit 76e1f6e57b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -162,7 +162,7 @@ namespace osu.Game.Online.Multiplayer
finally
{
// The task will be awaited in the future, so reset it so that the user doesn't get into a permanently faulted state if anything fails.
lock (joinOrLeaveTask)
lock (joinOrLeaveTaskLock)
{
if (joinOrLeaveTask == newTask)
joinOrLeaveTask = null;
@ -212,7 +212,7 @@ namespace osu.Game.Online.Multiplayer
finally
{
// The task will be awaited in the future, so reset it so that the user doesn't get into a permanently faulted state if anything fails.
lock (joinOrLeaveTask)
lock (joinOrLeaveTaskLock)
{
if (joinOrLeaveTask == newTask)
joinOrLeaveTask = null;