token: Validate args for gst_rtsp_token_is_allowed

See https://bugzilla.gnome.org/show_bug.cgi?id=710520
This commit is contained in:
Sebastian Rasmussen 2013-10-19 19:24:34 +02:00 committed by Wim Taymans
parent c9025a58e1
commit e4509ed92c

View file

@ -239,6 +239,9 @@ gst_rtsp_token_is_allowed (GstRTSPToken * token, const gchar * field)
{ {
gboolean result; gboolean result;
g_return_val_if_fail (GST_IS_RTSP_TOKEN (token), FALSE);
g_return_val_if_fail (field != NULL, FALSE);
if (!gst_structure_get_boolean (GST_RTSP_TOKEN_STRUCTURE (token), field, if (!gst_structure_get_boolean (GST_RTSP_TOKEN_STRUCTURE (token), field,
&result)) &result))
result = FALSE; result = FALSE;