File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -796,10 +796,10 @@ pub fn park() {
796
796
let mut m = thread. inner . lock . lock ( ) . unwrap ( ) ;
797
797
match thread. inner . state . compare_exchange ( EMPTY , PARKED , SeqCst , SeqCst ) {
798
798
Ok ( _) => { }
799
- Err ( NOTIFIED ) => {
799
+ Err ( NOTIFIED ) => {
800
800
// should consume this notification, so prohibit spurious wakeups in next park...
801
- thread. inner . state . store ( EMPTY , SeqCst ) ;
802
- return ;
801
+ thread. inner . state . store ( EMPTY , SeqCst ) ;
802
+ return ;
803
803
} , // notified after we locked
804
804
Err ( _) => panic ! ( "inconsistent park state" ) ,
805
805
}
@@ -886,10 +886,10 @@ pub fn park_timeout(dur: Duration) {
886
886
let m = thread. inner . lock . lock ( ) . unwrap ( ) ;
887
887
match thread. inner . state . compare_exchange ( EMPTY , PARKED , SeqCst , SeqCst ) {
888
888
Ok ( _) => { }
889
- Err ( NOTIFIED ) => {
889
+ Err ( NOTIFIED ) => {
890
890
// should consume this notification, so prohibit spurious wakeups in next park...
891
- thread. inner . state . store ( EMPTY , SeqCst ) ;
892
- return ;
891
+ thread. inner . state . store ( EMPTY , SeqCst ) ;
892
+ return ;
893
893
} , // notified after we locked
894
894
Err ( _) => panic ! ( "inconsistent park_timeout state" ) ,
895
895
}
You can’t perform that action at this time.
0 commit comments