gst/elements/gstbufferstore.c: don't try to make subbuffers bigger than they can be. (fixes #159970)

Original commit message from CVS:
* gst/elements/gstbufferstore.c:
(gst_buffer_store_add_buffer_func):
don't try to make subbuffers bigger than they can be. (fixes
#159970)
This commit is contained in:
Benjamin Otte 2004-11-30 23:45:36 +00:00
parent 88b88555a4
commit 802e18724d
3 changed files with 9 additions and 2 deletions

View file

@ -1,3 +1,10 @@
2004-12-01 Benjamin Otte <otte@gnome.org>
* gst/elements/gstbufferstore.c:
(gst_buffer_store_add_buffer_func):
don't try to make subbuffers bigger than they can be. (fixes
#159970)
2004-11-29 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* docs/gst/gstreamer-sections.txt:

View file

@ -208,7 +208,7 @@ gst_buffer_store_add_buffer_func (GstBufferStore * store, GstBuffer * buffer)
start_offset = GST_BUFFER_OFFSET (buffer) > start_offset ? 0 :
start_offset - GST_BUFFER_OFFSET (buffer);
sub = gst_buffer_create_sub (buffer, start_offset,
MIN (GST_BUFFER_SIZE (buffer),
MIN (GST_BUFFER_SIZE (buffer) - start_offset,
GST_BUFFER_OFFSET (current) - start_offset -
GST_BUFFER_OFFSET (buffer)));
g_assert (sub);

View file

@ -208,7 +208,7 @@ gst_buffer_store_add_buffer_func (GstBufferStore * store, GstBuffer * buffer)
start_offset = GST_BUFFER_OFFSET (buffer) > start_offset ? 0 :
start_offset - GST_BUFFER_OFFSET (buffer);
sub = gst_buffer_create_sub (buffer, start_offset,
MIN (GST_BUFFER_SIZE (buffer),
MIN (GST_BUFFER_SIZE (buffer) - start_offset,
GST_BUFFER_OFFSET (current) - start_offset -
GST_BUFFER_OFFSET (buffer)));
g_assert (sub);