Skip to content

Commit

Permalink
fix BufferMapCallbackC & SubmittedWorkDoneClosureC (#2787)
Browse files Browse the repository at this point in the history
  • Loading branch information
rajveermalviya authored Jun 18, 2022
1 parent 0d4d3f4 commit f27a978
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions wgpu-core/src/device/queue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ const WRITE_COMMAND_BUFFERS_PER_POOL: usize = 64;

#[repr(C)]
pub struct SubmittedWorkDoneClosureC {
callback: unsafe extern "C" fn(user_data: *mut u8),
user_data: *mut u8,
pub callback: unsafe extern "C" fn(user_data: *mut u8),
pub user_data: *mut u8,
}

unsafe impl Send for SubmittedWorkDoneClosureC {}
Expand Down
4 changes: 2 additions & 2 deletions wgpu-core/src/resource.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ unsafe impl<A: hal::Api> Sync for BufferMapState<A> {}

#[repr(C)]
pub struct BufferMapCallbackC {
callback: unsafe extern "C" fn(status: BufferMapAsyncStatus, user_data: *mut u8),
user_data: *mut u8,
pub callback: unsafe extern "C" fn(status: BufferMapAsyncStatus, user_data: *mut u8),
pub user_data: *mut u8,
}

unsafe impl Send for BufferMapCallbackC {}
Expand Down

0 comments on commit f27a978

Please sign in to comment.