diff --git a/gstreamer/src/buffer_pool.rs b/gstreamer/src/buffer_pool.rs index cad01b6c9..5e9338a26 100644 --- a/gstreamer/src/buffer_pool.rs +++ b/gstreamer/src/buffer_pool.rs @@ -296,11 +296,7 @@ impl> BufferPoolExtManual for O { &self, params: P, ) -> Result<::Buffer, ::FlowError> { - let params = params.into(); - let params_ptr = match params { - Some(params) => ¶ms.0 as *const _ as *mut _, - None => ptr::null_mut(), - }; + let params_ptr = params.into().to_glib_none().0 as *mut _; unsafe { let mut buffer = ptr::null_mut();