From ab21bf8c7e26e28979689d8ccb4197d344141b0f Mon Sep 17 00:00:00 2001 From: kuzeyardabulut <54737933+kuzeyardabulut@users.noreply.github.com> Date: Thu, 3 Aug 2023 18:59:23 +0300 Subject: [PATCH 1/2] restrict Sync/Send for ThreadPinned --- feather/plugin-host/src/thread_pinned.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/feather/plugin-host/src/thread_pinned.rs b/feather/plugin-host/src/thread_pinned.rs index dccc72c47..3568308c7 100644 --- a/feather/plugin-host/src/thread_pinned.rs +++ b/feather/plugin-host/src/thread_pinned.rs @@ -41,5 +41,5 @@ impl ThreadPinned { } } -unsafe impl Send for ThreadPinned {} -unsafe impl Sync for ThreadPinned {} +unsafe impl Send for ThreadPinned {} +unsafe impl Sync for ThreadPinned {} From f0c7db6a9d44037616bd4f71cb67f1af687721b6 Mon Sep 17 00:00:00 2001 From: kuzeyardabulut <54737933+kuzeyardabulut@users.noreply.github.com> Date: Thu, 3 Aug 2023 19:04:06 +0300 Subject: [PATCH 2/2] restrict Sync/Send for UnsafeSendSync --- feather/old/server/types/src/task.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/feather/old/server/types/src/task.rs b/feather/old/server/types/src/task.rs index b61a2e7f5..82001182f 100644 --- a/feather/old/server/types/src/task.rs +++ b/feather/old/server/types/src/task.rs @@ -27,8 +27,8 @@ unsafe impl Send for SyncFn {} /// Fake wrapper which causes a value to become `Send` and `Sync`. struct UnsafeSendSync(T); -unsafe impl Send for UnsafeSendSync {} -unsafe impl Sync for UnsafeSendSync {} +unsafe impl Send for UnsafeSendSync {} +unsafe impl Sync for UnsafeSendSync {} /// Global task manager. static TASK_MANAGER: OnceCell = OnceCell::new();