File tree 1 file changed +6
-4
lines changed
src/unix/bsd/freebsdlike/dragonfly 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,8 @@ impl ::dox::Clone for sem {
25
25
fn clone ( & self ) -> sem { * self }
26
26
}
27
27
28
+ use dox:: mem;
29
+
28
30
s ! {
29
31
30
32
pub struct exit_status {
@@ -805,25 +807,25 @@ f! {
805
807
}
806
808
807
809
pub fn CMSG_LEN ( length: :: c_uint) -> :: c_uint {
808
- _CMSG_ALIGN( mem:: size_of:: <:: cmsghdr>( ) ) + length as usize
810
+ ( _CMSG_ALIGN( mem:: size_of:: <:: cmsghdr>( ) ) + length as usize ) as u32
809
811
}
810
812
811
813
pub fn CMSG_NXTHDR ( mhdr: * const :: msghdr, cmsg: * const :: cmsghdr)
812
814
-> * mut :: cmsghdr
813
815
{
814
- let next = cmsg as usize + _CMSG_ALIGN( ( * cmsg) . cmsg_len)
816
+ let next = cmsg as usize + _CMSG_ALIGN( ( * cmsg) . cmsg_len as usize )
815
817
+ _CMSG_ALIGN( mem:: size_of:: <:: cmsghdr>( ) ) ;
816
818
let max = ( * mhdr) . msg_control as usize
817
819
+ ( * mhdr) . msg_controllen as usize ;
818
820
if next <= max {
819
- ( cmsg as usize + _CMSG_ALIGN( ( * cmsg) . cmsg_len) ) as * mut :: cmsghdr
821
+ ( cmsg as usize + _CMSG_ALIGN( ( * cmsg) . cmsg_len as usize ) ) as * mut :: cmsghdr
820
822
} else {
821
823
0 as * mut :: cmsghdr
822
824
}
823
825
}
824
826
825
827
pub fn CMSG_SPACE ( length: :: c_uint) -> :: c_uint {
826
- _CMSG_ALIGN( mem:: size_of:: <:: cmsghdr>( ) ) + _CMSG_ALIGN( length as usize )
828
+ ( _CMSG_ALIGN( mem:: size_of:: <:: cmsghdr>( ) ) + _CMSG_ALIGN( length as usize ) ) as u32
827
829
}
828
830
}
829
831
You can’t perform that action at this time.
0 commit comments