fix(native): invalid call to set mute behavior (#11764)
the error is only visible when turning build debug mode on
This commit is contained in:
@@ -30,11 +30,14 @@ impl CATapDescription {
|
|||||||
NSArray::from_retained_slice(&[NSNumber::initWithUnsignedInt(NSNumber::alloc(), process)]);
|
NSArray::from_retained_slice(&[NSNumber::initWithUnsignedInt(NSNumber::alloc(), process)]);
|
||||||
let obj: *mut AnyObject =
|
let obj: *mut AnyObject =
|
||||||
unsafe { msg_send![obj, initStereoMixdownOfProcesses: &*processes_array] };
|
unsafe { msg_send![obj, initStereoMixdownOfProcesses: &*processes_array] };
|
||||||
let obj: *mut AnyObject = unsafe { msg_send![obj, setMuteBehavior: 0 ] };
|
|
||||||
if obj.is_null() {
|
if obj.is_null() {
|
||||||
return Err(CoreAudioError::InitStereoMixdownOfProcessesFailed);
|
return Err(CoreAudioError::InitStereoMixdownOfProcessesFailed);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
unsafe {
|
||||||
|
let _: () = msg_send![obj, setMuteBehavior: 0_i64];
|
||||||
|
}
|
||||||
|
|
||||||
Ok(Self { inner: obj })
|
Ok(Self { inner: obj })
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user