GNOME Bugzilla – Bug 353121
gst_query_new_segment should initialize all structure fields
Last modified: 2006-08-28 08:45:47 UTC
gst_query_new_segment currently only initializes the format field, but not rate, start_value, and stop_value. This leads to assertions if you gst_query_parse_segment before you gst_query_set_segment. Other query constructors also initialize all fields even if their value isn't known yet, for example gst_query_new_position and gst_query_new_duration. Patch attached.
Created attachment 71710 [details] [review] Initialize all fields
Patch by: Torsten Schoenfeld <kaffeetisch at gmx dot de> * gst/gstquery.c: (gst_query_new_segment): * tests/check/gst/gstquery.c: (GST_START_TEST): Initialize variables when creating a new segment query. Fixes #353121.