mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-22 15:18:21 +00:00
gst/gstquery.c (gst_query_new_convert): Spew if we try to convert a negative value. Doesn't make much sense. Mostly t...
Original commit message from CVS: 2005-08-24 Andy Wingo <wingo@pobox.com> * gst/gstquery.c (gst_query_new_convert): Spew if we try to convert a negative value. Doesn't make much sense. Mostly this is here to force callers to ensure -1 maps to -1.
This commit is contained in:
parent
8aa248c92b
commit
438739a556
2 changed files with 8 additions and 0 deletions
|
@ -1,3 +1,9 @@
|
||||||
|
2005-08-24 Andy Wingo <wingo@pobox.com>
|
||||||
|
|
||||||
|
* gst/gstquery.c (gst_query_new_convert): Spew if we try to
|
||||||
|
convert a negative value. Doesn't make much sense. Mostly this is
|
||||||
|
here to force callers to ensure -1 maps to -1.
|
||||||
|
|
||||||
2005-08-24 Jan Schmidt <thaytan@mad.scientist.com>
|
2005-08-24 Jan Schmidt <thaytan@mad.scientist.com>
|
||||||
|
|
||||||
* docs/pwg/advanced-types.xml:
|
* docs/pwg/advanced-types.xml:
|
||||||
|
|
|
@ -368,6 +368,8 @@ gst_query_new_convert (GstFormat src_fmt, gint64 value, GstFormat dest_fmt)
|
||||||
GstQuery *query;
|
GstQuery *query;
|
||||||
GstStructure *structure;
|
GstStructure *structure;
|
||||||
|
|
||||||
|
g_return_val_if_fail (value >= 0, NULL);
|
||||||
|
|
||||||
structure = gst_structure_new ("GstQueryConvert",
|
structure = gst_structure_new ("GstQueryConvert",
|
||||||
"src_format", GST_TYPE_FORMAT, src_fmt,
|
"src_format", GST_TYPE_FORMAT, src_fmt,
|
||||||
"src_value", G_TYPE_INT64, value,
|
"src_value", G_TYPE_INT64, value,
|
||||||
|
|
Loading…
Reference in a new issue