mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
sample: no need to store the size of the sample structure inside the structure
This commit is contained in:
parent
e560d7a364
commit
fcd6e1f89c
1 changed files with 1 additions and 4 deletions
|
@ -37,8 +37,6 @@ struct _GstSample
|
|||
{
|
||||
GstMiniObject mini_object;
|
||||
|
||||
gsize slice_size;
|
||||
|
||||
GstBuffer *buffer;
|
||||
GstCaps *caps;
|
||||
GstSegment segment;
|
||||
|
@ -76,7 +74,7 @@ _gst_sample_free (GstSample * sample)
|
|||
if (sample->caps)
|
||||
gst_caps_unref (sample->caps);
|
||||
|
||||
g_slice_free1 (sample->slice_size, sample);
|
||||
g_slice_free1 (sizeof (GstSample), sample);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +108,6 @@ gst_sample_new (GstBuffer * buffer, GstCaps * caps, const GstSegment * segment,
|
|||
sample->mini_object.copy = (GstMiniObjectCopyFunction) _gst_sample_copy;
|
||||
sample->mini_object.free = (GstMiniObjectFreeFunction) _gst_sample_free;
|
||||
|
||||
sample->slice_size = sizeof (GstSample);
|
||||
sample->buffer = buffer ? gst_buffer_ref (buffer) : NULL;
|
||||
sample->caps = caps ? gst_caps_ref (caps) : NULL;
|
||||
|
||||
|
|
Loading…
Reference in a new issue