-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
While conducting an internal unsafe review, we identified a possible soundness issue in JobPort::Drop
Line 35 in b88296f
| unsafe { CloseHandle(self.completion_port) }; |
This is highly suspect when combined with #[derive(Clone)] on the struct: any use of Clone is likely to lead to a double-free. This will usually produce a harmless "invalid handle" error which this code will silently ignore, but if either HANDLE value is reused by the kernel before the second clone is dropped, undefined behavior seems possible.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels