diff options
author | Nugine <nugine@foxmail.com> | 2022-07-01 06:43:25 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-01 00:43:25 +0200 |
commit | a27acbc2ec63dd684cf57990b30d757cd0477d9b (patch) | |
tree | 1fa71c31cfebba14a9a7d74eca18dada3b57686b /core/ops.rs | |
parent | 3d8ba30ea0a4dfedcddcf11ecf2bf476cd1af4c3 (diff) |
fix(core): remove unsafe in OpsTracker (#15025)
Diffstat (limited to 'core/ops.rs')
-rw-r--r-- | core/ops.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/core/ops.rs b/core/ops.rs index 3d0d0ec70..a96681eb5 100644 --- a/core/ops.rs +++ b/core/ops.rs @@ -14,7 +14,6 @@ use futures::task::noop_waker; use futures::Future; use serde::Serialize; use std::cell::RefCell; -use std::cell::UnsafeCell; use std::ops::Deref; use std::ops::DerefMut; use std::pin::Pin; @@ -160,9 +159,7 @@ impl OpState { resource_table: Default::default(), get_error_class_fn: &|_| "Error", gotham_state: Default::default(), - tracker: OpsTracker { - ops: UnsafeCell::new(vec![Default::default(); ops_count]), - }, + tracker: OpsTracker::new(ops_count), } } } |