From a733bdb4f9b37d9ff471a93275802ed17dace070 Mon Sep 17 00:00:00 2001 From: mitchmindtree Date: Fri, 21 Jun 2019 03:11:20 +0200 Subject: [PATCH] Fix compile errors on macOS --- src/coreaudio/mod.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/coreaudio/mod.rs b/src/coreaudio/mod.rs index 40ccf17..1f5b831 100644 --- a/src/coreaudio/mod.rs +++ b/src/coreaudio/mod.rs @@ -10,7 +10,6 @@ use Format; use PauseStreamError; use PlayStreamError; use SupportedFormatsError; -use Sample; use SampleFormat; use SampleRate; use StreamData; @@ -55,7 +54,6 @@ use self::coreaudio::sys::{ kAudioFormatFlagIsFloat, kAudioFormatFlagIsPacked, kAudioFormatLinearPCM, - kAudioHardwareNoError, kAudioObjectPropertyElementMaster, kAudioObjectPropertyScopeOutput, kAudioOutputUnitProperty_CurrentDevice, @@ -790,7 +788,7 @@ impl EventLoop { if !stream.playing { if let Err(e) = stream.audio_unit.start() { - let description = format!("{}", std::error::Error::description(e)); + let description = format!("{}", std::error::Error::description(&e)); let err = BackendSpecificError { description }; return Err(err.into()); } @@ -805,7 +803,7 @@ impl EventLoop { if stream.playing { if let Err(e) = stream.audio_unit.stop() { - let description = format!("{}", std::error::Error::description(e)); + let description = format!("{}", std::error::Error::description(&e)); let err = BackendSpecificError { description }; return Err(err.into()); }