rem: gst_structure_get_double (s, "framerate", &bvw->priv->video_fps); gst_structure_get_int (s, "width", &bvw->priv->video_width); gst_structure_get_int (s, "height", &bvw->priv->video_height);
add: if (!(gst_structure_get_double (s, "framerate", &bvw->priv->video_fps) && gst_structure_get_int (s, "width", &bvw->priv->video_width) && gst_structure_get_int (s, "height", &bvw->priv->video_height))) return;
context: caps_set (GObject * obj,    GParamSpec * pspec, BaconVideoWidget * bvw){  GstPad *pad = GST_PAD (obj);  GstStructure *s;  if (!GST_PAD_CAPS (pad))    return;  s = gst_caps_get_structure (GST_PAD_CAPS (pad), 0);  if (s) {    const GValue *par;    gst_structure_get_double (s, "framerate", &bvw->priv->video_fps);    gst_structure_get_int (s, "width", &bvw->priv->video_width);    gst_structure_get_int (s, "height", &bvw->priv->video_height);    if ((par = gst_structure_get_value (s,                   "pixel-aspect-ratio"))) {      gint num = gst_value_get_fraction_numerator (par),          den = gst_value_get_fraction_denominator (par);      if (num > den)        bvw->priv->video_width *= (gfloat) num / den;      else        bvw->priv->video_height *= (gfloat) den / num;    }  }  /* and disable ourselves */  g_signal_handlers_disconnect_by_func (pad, caps_set, bvw);}