From 1cd0caf8b620acd52db7e1f02058266a555fadd6 Mon Sep 17 00:00:00 2001 From: Dimitris Apostolou Date: Sat, 19 Feb 2022 18:14:34 +0200 Subject: [PATCH] Fix typos --- asio-sys/src/bindings/mod.rs | 4 ++-- src/host/alsa/mod.rs | 2 +- src/host/wasapi/device.rs | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/asio-sys/src/bindings/mod.rs b/asio-sys/src/bindings/mod.rs index 36b2dee..db9168f 100644 --- a/asio-sys/src/bindings/mod.rs +++ b/asio-sys/src/bindings/mod.rs @@ -440,7 +440,7 @@ impl Driver { /// This will destroy any already allocated buffers. /// /// If buffersize is None then the preferred buffer size from ASIO is used, - /// otherwise the desired buffersize is used if the requeted size is within + /// otherwise the desired buffersize is used if the requested size is within /// the range of accepted buffersizes for the device. fn create_buffers( &self, @@ -842,7 +842,7 @@ fn asio_channel_info(channel: c_long, is_input: bool) -> Result Result { let channel_info = asio_channel_info(0, is_input)?; - Ok(FromPrimitive::from_i32(channel_info.type_).expect("unkown `ASIOSampletype` value")) + Ok(FromPrimitive::from_i32(channel_info.type_).expect("unknown `ASIOSampletype` value")) } /// ASIO uses null terminated c strings for driver names. diff --git a/src/host/alsa/mod.rs b/src/host/alsa/mod.rs index 974bb6d..41172d5 100644 --- a/src/host/alsa/mod.rs +++ b/src/host/alsa/mod.rs @@ -311,7 +311,7 @@ impl Device { let hw_params = alsa::pcm::HwParams::any(handle)?; - // TODO: check endianess + // TODO: check endianness const FORMATS: [(SampleFormat, alsa::pcm::Format); 3] = [ //SND_PCM_FORMAT_S8, //SND_PCM_FORMAT_U8, diff --git a/src/host/wasapi/device.rs b/src/host/wasapi/device.rs index 70445cf..3828177 100644 --- a/src/host/wasapi/device.rs +++ b/src/host/wasapi/device.rs @@ -367,7 +367,7 @@ impl Device { len += 1; } - // Create the utf16 slice and covert it into a string. + // Create the utf16 slice and convert it into a string. let name_slice = slice::from_raw_parts(ptr_utf16, len as usize); let name_os_string: OsString = OsStringExt::from_wide(name_slice); let name_string = match name_os_string.into_string() { @@ -959,7 +959,7 @@ impl Device { impl PartialEq for Device { #[inline] fn eq(&self, other: &Device) -> bool { - // Use case: In oder to check whether the default device has changed + // Use case: In order to check whether the default device has changed // the client code might need to compare the previous default device with the current one. // The pointer comparison (`self.device == other.device`) don't work there, // because the pointers are different even when the default device stays the same.