diff options
author | Matthew Gregan <[email protected]> | 2012-10-26 16:58:31 +1300 |
---|---|---|
committer | Matthew Gregan <[email protected]> | 2012-10-26 16:58:31 +1300 |
commit | e5837ecbb2389abd7e6635f4339878c5e4c1e1d5 (patch) | |
tree | fc6d289b7acfdcb5cd526b728e3c9f3d32976590 | |
parent | 9d44b732da8f1cbe8ff8f721b2c2ce18c6a11bf4 (diff) | |
download | cubeb-e5837ecbb2389abd7e6635f4339878c5e4c1e1d5.tar.gz cubeb-e5837ecbb2389abd7e6635f4339878c5e4c1e1d5.zip |
audiounit: make unit deinit failures non-fatal too.
-rw-r--r-- | src/cubeb_audiounit.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/cubeb_audiounit.c b/src/cubeb_audiounit.c index 9fd46c4..f661a54 100644 --- a/src/cubeb_audiounit.c +++ b/src/cubeb_audiounit.c @@ -222,19 +222,14 @@ cubeb_stream_init(cubeb * context, cubeb_stream ** stream, char const * stream_n void cubeb_stream_destroy(cubeb_stream * stm) { - OSStatus r; + int r; stm->shutdown = 1; if (stm->unit) { - r = AudioOutputUnitStop(stm->unit); - assert(r == 0); - - r = AudioUnitUninitialize(stm->unit); - assert(r == 0); - - r = CloseComponent(stm->unit); - assert(r == 0); + AudioOutputUnitStop(stm->unit); + AudioUnitUninitialize(stm->unit); + CloseComponent(stm->unit); } r = pthread_mutex_destroy(&stm->mutex); |