13
0

Coreaudio: ignore [expected] SR changes.

Don’t disconnect from engine if sample-rate change
happens during initialization.
This commit is contained in:
Robin Gareus 2015-06-07 02:32:39 +02:00
parent c2f1363387
commit e801155dde

View File

@ -1715,6 +1715,12 @@ CoreAudioBackend::buffer_size_callback ()
void void
CoreAudioBackend::sample_rate_callback () CoreAudioBackend::sample_rate_callback ()
{ {
if (_preinit) {
#ifndef NDEBUG
printf("Samplerate change during initialization.\n");
#endif
return;
}
_pcmio->set_error_callback (NULL, NULL); _pcmio->set_error_callback (NULL, NULL);
_pcmio->set_sample_rate_callback (NULL, NULL); _pcmio->set_sample_rate_callback (NULL, NULL);
_pcmio->set_xrun_callback (NULL, NULL); _pcmio->set_xrun_callback (NULL, NULL);