#[repr(C)]pub struct SockAddrRc {
pub family: u16,
pub bdaddr: [u8; 6],
pub channel: u8,
}Expand description
struct sockaddr_rc from bluetooth/rfcomm.h.
Not packed, unlike SockAddrL2: the kernel’s struct is plain, so it
is 2 + 6 + 1 = 9 bytes of fields and 10 with the trailing padding, and
rfcomm_sock_connect refuses any length below sizeof(struct sockaddr_rc)
with EINVAL. Packed, this was 9, so every outbound RFCOMM connection
failed before reaching the radio — while bind, which tolerates a short
address, worked, and made the listener look fine.
Fields§
§family: u16§bdaddr: [u8; 6]§channel: u8Trait Implementations§
Source§impl Clone for SockAddrRc
impl Clone for SockAddrRc
impl Copy for SockAddrRc
Auto Trait Implementations§
impl Forget for SockAddrRc
impl Freeze for SockAddrRc
impl Move for SockAddrRc
impl RefUnwindSafe for SockAddrRc
impl Send for SockAddrRc
impl Sync for SockAddrRc
impl Unpin for SockAddrRc
impl UnsafeUnpin for SockAddrRc
impl UnwindSafe for SockAddrRc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more