Loading system/gd/rust/linux/mgmt/src/state_machine.rs +3 −0 Original line number Diff line number Diff line Loading @@ -2185,14 +2185,17 @@ mod tests { get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth0.pid"), Some(VirtualHciIndex(0)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth0.pid"), Some(VirtualHciIndex(0))); assert_eq!( get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth1.pid"), Some(VirtualHciIndex(1)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth1.pid"), Some(VirtualHciIndex(1))); assert_eq!( get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth10.pid"), Some(VirtualHciIndex(10)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth10.pid"), Some(VirtualHciIndex(10))); assert_eq!(get_hci_index_from_pid_path("/var/run/bluetooth/garbage"), None); assert_eq!(get_hci_index_from_pid_path("garbage"), None); } Loading system/gd/rust/linux/stack/src/bluetooth.rs +1 −1 Original line number Diff line number Diff line Loading @@ -1367,7 +1367,7 @@ impl Bluetooth { /// Disconnect the device if no HID or media profiles are enabled. pub fn disconnect_if_no_media_or_hid_profiles_connected(&mut self, device_address: RawAddress) { let context = match self.remote_devices.get(&device_address) { Some(context) => context.clone(), Some(context) => context, None => return, }; let device = context.info.clone(); Loading system/gd/rust/topshim/build.rs +1 −1 Original line number Diff line number Diff line Loading @@ -63,7 +63,7 @@ fn main() { .opaque_type("std::.*") // Whitelist std::string though because we use it a lot .allowlist_type("std::string") .rustfmt_bindings(true) .formatter(bindgen::Formatter::Rustfmt) .derive_debug(true) .derive_partialeq(true) .derive_eq(true) Loading Loading
system/gd/rust/linux/mgmt/src/state_machine.rs +3 −0 Original line number Diff line number Diff line Loading @@ -2185,14 +2185,17 @@ mod tests { get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth0.pid"), Some(VirtualHciIndex(0)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth0.pid"), Some(VirtualHciIndex(0))); assert_eq!( get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth1.pid"), Some(VirtualHciIndex(1)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth1.pid"), Some(VirtualHciIndex(1))); assert_eq!( get_hci_index_from_pid_path("/var/run/bluetooth/bluetooth10.pid"), Some(VirtualHciIndex(10)) ); assert_eq!(get_hci_index_from_pid_path("bluetooth10.pid"), Some(VirtualHciIndex(10))); assert_eq!(get_hci_index_from_pid_path("/var/run/bluetooth/garbage"), None); assert_eq!(get_hci_index_from_pid_path("garbage"), None); } Loading
system/gd/rust/linux/stack/src/bluetooth.rs +1 −1 Original line number Diff line number Diff line Loading @@ -1367,7 +1367,7 @@ impl Bluetooth { /// Disconnect the device if no HID or media profiles are enabled. pub fn disconnect_if_no_media_or_hid_profiles_connected(&mut self, device_address: RawAddress) { let context = match self.remote_devices.get(&device_address) { Some(context) => context.clone(), Some(context) => context, None => return, }; let device = context.info.clone(); Loading
system/gd/rust/topshim/build.rs +1 −1 Original line number Diff line number Diff line Loading @@ -63,7 +63,7 @@ fn main() { .opaque_type("std::.*") // Whitelist std::string though because we use it a lot .allowlist_type("std::string") .rustfmt_bindings(true) .formatter(bindgen::Formatter::Rustfmt) .derive_debug(true) .derive_partialeq(true) .derive_eq(true) Loading