basevideo: Fail if caps don't contain a framerate field

Return false from the caps parsing function if there is no framerate
field in the provided caps

Merging previous commit into current codebase.
This commit is contained in:
Jan Schmidt 2009-10-05 15:47:58 +01:00 committed by David Schleef
parent 13848cc93b
commit efb8a4324c

View file

@ -128,7 +128,8 @@ gst_base_video_state_from_caps (GstVideoState * state, GstCaps * caps)
gst_video_format_parse_caps (caps, &state->format,
&state->width, &state->height);
gst_video_parse_caps_framerate (caps, &state->fps_n, &state->fps_d);
if (!gst_video_parse_caps_framerate (caps, &state->fps_n, &state->fps_d))
return FALSE;
state->par_n = 1;
state->par_d = 1;