summaryrefslogtreecommitdiff
path: root/avmedia
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2014-12-06 01:07:11 +0100
committerNoel Grandin <noelgrandin@gmail.com>2014-12-08 08:01:58 +0000
commit3338f479182a5face7f143bdc4b9ea9067028887 (patch)
tree1f9ae6785720b3a086a166a906bcb0a7340545d6 /avmedia
parent664e64a1901d84137245c14ecfa9432123238bfa (diff)
reduce scope of local variables
This eliminates some of the warnings from Cppcheck report of 2014-11-29. Change-Id: Id5bf885de12a6de262d2cca9fa71627ac67f50d9 Reviewed-on: https://gerrit.libreoffice.org/13330 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'avmedia')
-rw-r--r--avmedia/source/gstreamer/gstplayer.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/avmedia/source/gstreamer/gstplayer.cxx b/avmedia/source/gstreamer/gstplayer.cxx
index cc44a4a9347d..88e62cfb9d1f 100644
--- a/avmedia/source/gstreamer/gstplayer.cxx
+++ b/avmedia/source/gstreamer/gstplayer.cxx
@@ -304,14 +304,13 @@ GstBusSyncReply Player::processSyncMessage( GstMessage *message )
}
if( mnWidth == 0 ) {
GstPad *pad = NULL;
- GstCaps *caps;
g_signal_emit_by_name( mpPlaybin, "get-video-pad", 0, &pad );
if( pad ) {
int w = 0, h = 0;
- caps = gst_pad_get_current_caps( pad );
+ GstCaps *caps = gst_pad_get_current_caps( pad );
if( gst_structure_get( gst_caps_get_structure( caps, 0 ),
"width", G_TYPE_INT, &w,