File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -796,10 +796,10 @@ pub fn park() {
796796 let mut m = thread. inner . lock . lock ( ) . unwrap ( ) ;
797797 match thread. inner . state . compare_exchange ( EMPTY , PARKED , SeqCst , SeqCst ) {
798798 Ok ( _) => { }
799- Err ( NOTIFIED ) => {
799+ Err ( NOTIFIED ) => {
800800 // 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 ;
803803 } , // notified after we locked
804804 Err ( _) => panic ! ( "inconsistent park state" ) ,
805805 }
@@ -886,10 +886,10 @@ pub fn park_timeout(dur: Duration) {
886886 let m = thread. inner . lock . lock ( ) . unwrap ( ) ;
887887 match thread. inner . state . compare_exchange ( EMPTY , PARKED , SeqCst , SeqCst ) {
888888 Ok ( _) => { }
889- Err ( NOTIFIED ) => {
889+ Err ( NOTIFIED ) => {
890890 // 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 ;
893893 } , // notified after we locked
894894 Err ( _) => panic ! ( "inconsistent park_timeout state" ) ,
895895 }
You can’t perform that action at this time.
0 commit comments