mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-15 22:01:27 +00:00
buffer: do not touch memory tag flag when copying buffer flags
The tag memory flag will be set later if the memory is also copied. This patch avoids buffers being freed needlessly in bufferpools. https://bugzilla.gnome.org/show_bug.cgi?id=735574
This commit is contained in:
parent
ce6e24e68a
commit
efa5a41dbc
1 changed files with 5 additions and 1 deletions
|
@ -397,7 +397,11 @@ gst_buffer_copy_into (GstBuffer * dest, GstBuffer * src,
|
|||
|
||||
if (flags & GST_BUFFER_COPY_FLAGS) {
|
||||
/* copy flags */
|
||||
GST_MINI_OBJECT_FLAGS (dest) = GST_MINI_OBJECT_FLAGS (src);
|
||||
guint flags_mask = ~GST_BUFFER_FLAG_TAG_MEMORY;
|
||||
|
||||
GST_MINI_OBJECT_FLAGS (dest) =
|
||||
(GST_MINI_OBJECT_FLAGS (src) & flags_mask) |
|
||||
(GST_MINI_OBJECT_FLAGS (dest) & ~flags_mask);
|
||||
}
|
||||
|
||||
if (flags & GST_BUFFER_COPY_TIMESTAMPS) {
|
||||
|
|
Loading…
Reference in a new issue