File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -40,12 +40,12 @@ pub unsafe fn weaken_task(f: &fn(Port<ShutdownMsg>)) {
4040 let task = get_task_id ( ) ;
4141 // Expect the weak task service to be alive
4242 assert service. try_send ( RegisterWeakTask ( task, shutdown_chan) ) ;
43- unsafe { rust_inc_kernel_live_count ( ) ; }
43+ unsafe { rust_dec_kernel_live_count ( ) ; }
4444 do fn& ( ) {
4545 let shutdown_port = swap_unwrap ( & mut * shutdown_port) ;
4646 f ( shutdown_port)
4747 } . finally || {
48- unsafe { rust_dec_kernel_live_count ( ) ; }
48+ unsafe { rust_inc_kernel_live_count ( ) ; }
4949 // Service my have already exited
5050 service. send ( UnregisterWeakTask ( task) ) ;
5151 }
@@ -78,11 +78,11 @@ fn create_global_service() -> ~WeakTaskService {
7878 let port = swap_unwrap ( & mut * port) ;
7979 // The weak task service is itself a weak task
8080 debug ! ( "weakening the weak service task" ) ;
81- unsafe { rust_inc_kernel_live_count ( ) ; }
81+ unsafe { rust_dec_kernel_live_count ( ) ; }
8282 run_weak_task_service ( port) ;
8383 } . finally {
8484 debug ! ( "unweakening the weak service task" ) ;
85- unsafe { rust_dec_kernel_live_count ( ) ; }
85+ unsafe { rust_inc_kernel_live_count ( ) ; }
8686 }
8787 }
8888
You can’t perform that action at this time.
0 commit comments