diff options
author | Eoin O'Neill <eoinoneill1991@gmail.com> | 2022-12-09 22:39:14 -0800 |
---|---|---|
committer | Yuri Sizov <yuris@humnom.net> | 2023-04-26 14:51:00 +0200 |
commit | 5120afc236c9d6425bc77ea03c93a7a5d5169a08 (patch) | |
tree | 90a92166837b1e3b574a7e6626b937ac4474ba70 /drivers/coreaudio | |
parent | 4b4556179e541ef100202a1270e678f3bcac7fb6 (diff) |
Fix crash caused by invalid mix_rate assignment due to bogus
project settings.
We'll default to a sensible value in the case that a user has
somehow managed to modify the configuration file incorrectly.
Closes 69819
(cherry picked from commit 5a08091168782a924cd3a23baf31c5cd4cd63906)
Diffstat (limited to 'drivers/coreaudio')
-rw-r--r-- | drivers/coreaudio/audio_driver_coreaudio.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/coreaudio/audio_driver_coreaudio.cpp b/drivers/coreaudio/audio_driver_coreaudio.cpp index 2c959bb07b..4011727433 100644 --- a/drivers/coreaudio/audio_driver_coreaudio.cpp +++ b/drivers/coreaudio/audio_driver_coreaudio.cpp @@ -116,7 +116,7 @@ Error AudioDriverCoreAudio::init() { break; } - mix_rate = GLOBAL_GET("audio/driver/mix_rate"); + mix_rate = _get_configured_mix_rate(); memset(&strdesc, 0, sizeof(strdesc)); strdesc.mFormatID = kAudioFormatLinearPCM; @@ -405,7 +405,7 @@ Error AudioDriverCoreAudio::init_input_device() { break; } - mix_rate = GLOBAL_GET("audio/driver/mix_rate"); + mix_rate = _get_configured_mix_rate(); memset(&strdesc, 0, sizeof(strdesc)); strdesc.mFormatID = kAudioFormatLinearPCM; |