From eefb8255cd9359ca39b34fda8003abf1f0af4c86 Mon Sep 17 00:00:00 2001 From: hwsmm <9151706+hwsmm@users.noreply.github.com> Date: Sat, 21 Sep 2024 17:39:59 +0900 Subject: [PATCH] Rename a variable --- osu.Framework/Audio/Track/TrackSDL3AudioPlayer.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/osu.Framework/Audio/Track/TrackSDL3AudioPlayer.cs b/osu.Framework/Audio/Track/TrackSDL3AudioPlayer.cs index 53822554b9..94aa965907 100644 --- a/osu.Framework/Audio/Track/TrackSDL3AudioPlayer.cs +++ b/osu.Framework/Audio/Track/TrackSDL3AudioPlayer.cs @@ -77,7 +77,7 @@ private void prepareArray(long wanted) internal void PrepareStream(long byteLength = 3 * 60 * 44100 * 2 * 4) { - if (disposedValue) + if (isDisposed) return; if (AudioData == null) @@ -88,7 +88,7 @@ internal void PrepareStream(long byteLength = 3 * 60 * 44100 * 2 * 4) internal void PutSamplesInStream(byte[] next, int length) { - if (disposedValue) + if (isDisposed) return; if (AudioData == null) @@ -108,7 +108,7 @@ internal void PutSamplesInStream(byte[] next, int length) internal void DonePutting() { - if (disposedValue) + if (isDisposed) return; // Saved seek was over data length @@ -258,14 +258,14 @@ public virtual void Seek(double seek) } } - private bool disposedValue; + private volatile bool isDisposed; protected virtual void Dispose(bool disposing) { - if (!disposedValue) + if (!isDisposed) { AudioData = null; - disposedValue = true; + isDisposed = true; } }