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 789902 - value: Fix out-of-bound calculation
value: Fix out-of-bound calculation
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
Other All
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Reported: 2017-11-04 12:32 UTC by Edward Hervey
Modified: 2018-11-03 12:42 UTC
See Also:
GNOME target: ---
GNOME version: ---

value: Fix out-of-bound calculation (2.37 KB, patch)
2017-11-04 12:32 UTC, Edward Hervey
none Details | Review

Description Edward Hervey 2017-11-04 12:32:25 UTC
See patch
Comment 1 Edward Hervey 2017-11-04 12:32:30 UTC
Created attachment 362957 [details] [review]
value: Fix out-of-bound calculation

This was introduced in 2001 by 39533f4364b7f3fd8b54f87039acebc705d68c3a
 "gstvalue: add stepped ranges"

The problem is that we could have a valid range with [0, MAXINT32]

And the resulting n1 and n2 values would be out of bound.

After reading the code, it seems as though that "+ 1" was not meant to
be there.

the various checks being done with those values are:
* if (n1 != n2) # having a +1 on both doesn't change anything
* if (n1 == 0)  # That would never be reached because of the +1
* if (n1 > 1) # commented as "if more than one value"
Comment 2 GStreamer system administrator 2018-11-03 12:42:48 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: