File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,8 @@ pub struct Mutex { inner: atomic::AtomicUint }
22
22
23
23
pub const MUTEX_INIT : Mutex = Mutex { inner : atomic:: INIT_ATOMIC_UINT } ;
24
24
25
+ unsafe impl Sync for Mutex { }
26
+
25
27
#[ inline]
26
28
pub unsafe fn raw ( m : & Mutex ) -> ffi:: LPCRITICAL_SECTION {
27
29
m. get ( )
Original file line number Diff line number Diff line change @@ -559,6 +559,8 @@ pub struct UnixListener {
559
559
name : CString ,
560
560
}
561
561
562
+ unsafe impl Sync for UnixListener { }
563
+
562
564
impl UnixListener {
563
565
pub fn bind ( addr : & CString ) -> IoResult < UnixListener > {
564
566
// Although we technically don't need the pipe until much later, we
@@ -603,11 +605,15 @@ pub struct UnixAcceptor {
603
605
deadline : u64 ,
604
606
}
605
607
608
+ unsafe impl Sync for UnixAcceptor { }
609
+
606
610
struct AcceptorState {
607
611
abort : Event ,
608
612
closed : atomic:: AtomicBool ,
609
613
}
610
614
615
+ unsafe impl Sync for AcceptorState { }
616
+
611
617
impl UnixAcceptor {
612
618
pub fn accept ( & mut self ) -> IoResult < UnixStream > {
613
619
// This function has some funky implementation details when working with
You can’t perform that action at this time.
0 commit comments