Skip to content

Commit

Permalink
Added drop impl to GLBufferDataReceiver
Browse files Browse the repository at this point in the history
  • Loading branch information
errata-c authored and jdm committed Dec 22, 2021
1 parent 65d8c7d commit d666f12
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions gl/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1514,6 +1514,14 @@ pub struct GLBufferDataReceiver {
target: BufferTarget,
}

impl Drop for GLBufferDataReceiver {
fn drop(&mut self) {
unsafe {
gl::DeleteSync(self.gl_sync);
}
}
}

pub struct GLTextureDataReceiver {
gl_pixel_buffer: GLuint,
gl_sync: GLsync,
Expand Down

0 comments on commit d666f12

Please sign in to comment.