diff options
| author | sl1nk3.s <sl1nk3.s@gmail.com> | 2009-06-03 20:09:48 +0000 |
|---|---|---|
| committer | sl1nk3.s <sl1nk3.s@gmail.com> | 2009-06-03 20:09:48 +0000 |
| commit | 69055f8d428af33cb8ea202595ed91da1cc758a3 (patch) | |
| tree | dfc033bb48208de831f42b6afc0d7b41c3aaccde /Source/Core | |
| parent | 16a9e33b85f69ecd4844f3a052e2a4af05d80a5f (diff) | |
Tiny crash fix for the wiimote plugin as well as a safer check for the volume in DSP HLE
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3314 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/AudioCommon/Src/DSoundStream.cpp | 2 | ||||
| -rw-r--r-- | Source/Core/AudioCommon/Src/DSoundStream.h | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/Source/Core/AudioCommon/Src/DSoundStream.cpp b/Source/Core/AudioCommon/Src/DSoundStream.cpp index 94a26bd81b..251e892647 100644 --- a/Source/Core/AudioCommon/Src/DSoundStream.cpp +++ b/Source/Core/AudioCommon/Src/DSoundStream.cpp @@ -160,7 +160,7 @@ void DSound::SetVolume(int volume) m_volume = (int)floor(log10((float)volume) * 5000.0f) - 10000; soundCriticalSection.Enter(); - if (ds != NULL) + if (dsBuffer != NULL) dsBuffer->SetVolume(m_volume); soundCriticalSection.Leave(); } diff --git a/Source/Core/AudioCommon/Src/DSoundStream.h b/Source/Core/AudioCommon/Src/DSoundStream.h index 17f91d27d3..e38c045c09 100644 --- a/Source/Core/AudioCommon/Src/DSoundStream.h +++ b/Source/Core/AudioCommon/Src/DSoundStream.h @@ -68,6 +68,8 @@ public: , totalRenderedBytes(0) , currentPos(0) , lastPos(0) + , dsBuffer(0) + , ds(0) {} virtual ~DSound() {} |
