diff options
Diffstat (limited to 'examples/dining_philosophers.rs')
| -rw-r--r-- | examples/dining_philosophers.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/dining_philosophers.rs b/examples/dining_philosophers.rs index f8657df..35aa330 100644 --- a/examples/dining_philosophers.rs +++ b/examples/dining_philosophers.rs @@ -46,7 +46,7 @@ struct Philosopher { impl Philosopher { fn cycle(&self) { - let key = ThreadKey::lock().unwrap(); + let key = ThreadKey::get().unwrap(); thread::sleep(Duration::from_secs(1)); // safety: no philosopher asks for the same fork twice |
