Skip to content

Commit

Permalink
Mark InnerPicture as Send+Sync
Browse files Browse the repository at this point in the history
`Picture` already was and it's just a ref-counting wrapper around it.

Fixes #95
  • Loading branch information
sdroege committed Mar 26, 2024
1 parent 73fa84a commit f8dc581
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -413,8 +413,6 @@ impl Decoder {
} else {
let inner = InnerPicture { pic };
Ok(Picture {
// https://github.com/rust-av/dav1d-rs/issues/95
#[allow(clippy::arc_with_non_send_sync)]
inner: Arc::new(inner),
})
}
Expand Down Expand Up @@ -734,6 +732,9 @@ impl Picture {
unsafe impl Send for Picture {}
unsafe impl Sync for Picture {}

unsafe impl Send for InnerPicture {}
unsafe impl Sync for InnerPicture {}

impl Drop for InnerPicture {
fn drop(&mut self) {
unsafe {
Expand Down

0 comments on commit f8dc581

Please sign in to comment.