vp9enc: do not dereference NULL pointer

Coverity 1197703
This commit is contained in:
Vincent Penquerc'h 2014-05-05 14:33:38 +01:00
parent 9589c43516
commit 1da2fd457d

View file

@ -932,7 +932,7 @@ gst_vp9_enc_set_property (GObject * object, guint prop_id,
memset (&gst_vp9_enc->cfg.ts_layer_id, 0, memset (&gst_vp9_enc->cfg.ts_layer_id, 0,
sizeof (gst_vp9_enc->cfg.ts_layer_id)); sizeof (gst_vp9_enc->cfg.ts_layer_id));
if (va->n_values > VPX_TS_MAX_PERIODICITY) { if (va && va->n_values > VPX_TS_MAX_PERIODICITY) {
g_warning ("%s: Only %d sized layer sequences allowed at maximum", g_warning ("%s: Only %d sized layer sequences allowed at maximum",
GST_ELEMENT_NAME (gst_vp9_enc), VPX_TS_MAX_PERIODICITY); GST_ELEMENT_NAME (gst_vp9_enc), VPX_TS_MAX_PERIODICITY);
} else if (va) { } else if (va) {