We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9316592 commit d4198d7Copy full SHA for d4198d7
1 file changed
rust/rubydex-sys/src/graph_api.rs
@@ -43,9 +43,6 @@ pub fn with_graph<F, T>(pointer: GraphPointer, action: F) -> T
43
where
44
F: FnOnce(&Graph) -> T,
45
{
46
- // Create a shared reference directly from the raw pointer. This avoids Box::from_raw,
47
- // which would imply unique ownership and create a temporary &mut Graph — UB when
48
- // multiple Ractors read the same shared, frozen graph concurrently.
49
let graph = unsafe { &*pointer.cast::<Graph>() };
50
action(graph)
51
}
0 commit comments