diff options
Diffstat (limited to 'gst/flv/gstflvmux.c')
-rw-r--r-- | gst/flv/gstflvmux.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gst/flv/gstflvmux.c b/gst/flv/gstflvmux.c index 95dc449a4..48f8b6604 100644 --- a/gst/flv/gstflvmux.c +++ b/gst/flv/gstflvmux.c @@ -830,6 +830,7 @@ tags: if (mux->have_video) { GstPad *video_pad = NULL; + GstCaps *caps = NULL; GstFlvPad *cpad; GSList *l = mux->collect->data; @@ -841,8 +842,11 @@ tags: } } - if (video_pad && gst_pad_has_current_caps (video_pad)) { - GstCaps *caps; + if (video_pad) { + caps = gst_pad_get_current_caps (video_pad); + } + + if (caps != NULL) { GstStructure *s; gint size; gint num, den; @@ -855,7 +859,6 @@ tags: script_tag = gst_buffer_append (script_tag, tmp); tags_written++; - caps = gst_pad_get_current_caps (video_pad); s = gst_caps_get_structure (caps, 0); gst_caps_unref (caps); |