projects
/
platform
/
upstream
/
gstreamer.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7ecef53
)
bufferlist: Warn if copying a buffer fails in gst_buffer_list_copy_deep()
author
Sebastian Dröge
<sebastian@centricular.com>
Wed, 24 Jun 2015 08:52:02 +0000
(10:52 +0200)
committer
Sebastian Dröge
<sebastian@centricular.com>
Wed, 24 Jun 2015 08:52:56 +0000
(10:52 +0200)
gst/gstbufferlist.c
patch
|
blob
|
history
diff --git
a/gst/gstbufferlist.c
b/gst/gstbufferlist.c
index
2ae3f2f
..
dabcd6a
100644
(file)
--- a/
gst/gstbufferlist.c
+++ b/
gst/gstbufferlist.c
@@
-389,7
+389,16
@@
gst_buffer_list_copy_deep (const GstBufferList * list)
len = list->n_buffers;
for (i = 0; i < len; i++) {
GstBuffer *old = list->buffers[i];
- gst_buffer_list_insert (result, i, gst_buffer_copy_deep (old));
+ GstBuffer *new = gst_buffer_copy_deep (old);
+
+ if (G_LIKELY (new)) {
+ gst_buffer_list_insert (result, i, new);
+ } else {
+ g_warning
+ ("Failed to deep copy buffer %p while deep "
+ "copying buffer list %p. Buffer list copy "
+ "will be incomplete", old, list);
+ }
}
return result;