kmssink: initialize variable
authorVíctor Manuel Jáquez Leal <vjaquez@igalia.com>
Mon, 10 Jul 2017 11:27:40 +0000 (13:27 +0200)
committerVíctor Manuel Jáquez Leal <vjaquez@igalia.com>
Mon, 10 Jul 2017 11:32:49 +0000 (13:32 +0200)
Otherwise clang complains:

gstkmssink.c:1192:7: warning: variable 'buf' is used uninitialized
whenever 'if' condition is true [-Wsometimes-uninitialized]

sys/kms/gstkmssink.c

index e990039d5f61365a08f56dbe39ed64a3b721b89d..bf92e6d9e8cd7a88cc0f82d3385b4fc335ee422c 100644 (file)
@@ -1189,6 +1189,7 @@ gst_kms_sink_copy_to_dumb_buffer (GstKMSSink * self, GstBuffer * inbuf)
   gboolean success;
   GstBuffer *buf;
 
+  buf = NULL;
   if (!gst_buffer_pool_set_active (self->pool, TRUE))
     goto activate_pool_failed;