After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 529018 - gst_ogm_parse_stream_header creates fraction value with wrong denominator argument width (64 bits)
gst_ogm_parse_stream_header creates fraction value with wrong denominator arg...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other All
: Normal normal
: 0.10.20
Assigned To: GStreamer Maintainers
GStreamer Maintainers
: 466393 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2008-04-20 11:22 UTC by Arek Korbik
Modified: 2009-04-08 12:12 UTC
See Also:
GNOME target: ---
GNOME version: 2.21/2.22



Description Arek Korbik 2008-04-20 11:22:23 UTC
Please describe the problem:
gst_ogm_parse_stream pases ogm->hdr.time_unit (which is gint64) directly to the gst_set_caps_simple for a GST_TYPE_FRACTION value. The arguments are passed va-style, but the eventual gst_value_set_fraction() expects and receives 32-bit integers. 

This is wrong, but it's mostly affecting the big endian machines because of the lack of byte reordering - gst_value_set_fraction() receives the most significant half of the denominator which will be 0 in most of the cases.


Steps to reproduce:


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Sebastian Dröge (slomo) 2008-04-20 11:41:40 UTC
2008-04-20  Sebastian Dröge  <slomo@circular-chaos.org>

	* ext/ogg/gstogmparse.c: (gst_ogm_parse_stream_header):
	GST_TYPE_FRACTION contains gints so correctly cast gint64 arguments to
	vaargs functions to gint. Otherwise the fractions will get 0 set
	instead of the correct value on big endian systems. Fixes bug #529018.
Comment 2 Tim-Philipp Müller 2009-04-08 12:12:02 UTC
*** Bug 466393 has been marked as a duplicate of this bug. ***