about summary refs log tree commit diff
path: root/src/libgreen
diff options
context:
space:
mode:
Diffstat (limited to 'src/libgreen')
-rw-r--r--src/libgreen/sched.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libgreen/sched.rs b/src/libgreen/sched.rs
index da4f0a3b68a..c8b84d445db 100644
--- a/src/libgreen/sched.rs
+++ b/src/libgreen/sched.rs
@@ -1470,7 +1470,6 @@ mod test {
                     LOCK.signal();   // wakeup waiting scheduler
                     LOCK.wait();     // wait for them to grab the lock
                     LOCK.unlock();
-                    LOCK.destroy();  // now we're guaranteed they have no locks
                 }
             })));
             drop(handle);
@@ -1478,6 +1477,6 @@ mod test {
             fin_po.recv();
             pool.shutdown();
         }
-
+        unsafe { LOCK.destroy(); }
     }
 }