diff --git a/src/gscam.cpp b/src/gscam.cpp index d0c6cc9..9e91bc4 100644 --- a/src/gscam.cpp +++ b/src/gscam.cpp @@ -391,8 +391,10 @@ namespace gscam { #if (GST_VERSION_MAJOR == 1) gst_memory_unmap(memory, &info); gst_memory_unref(memory); -#endif + gst_sample_unref(sample); +#else gst_buffer_unref(buf); +#endif } ros::spinOnce();