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 745515 - level: infinite loop when interval is set to low values
level: infinite loop when interval is set to low values
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
unspecified
Other Linux
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-03-03 10:50 UTC by Vineeth
Modified: 2015-04-23 23:52 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
fix when blocksize is 0 (1.09 KB, patch)
2015-03-03 10:51 UTC, Vineeth
none Details | Review
fix when blocksize is 0 (1.04 KB, patch)
2015-03-04 10:41 UTC, Vineeth
none Details | Review

Description Vineeth 2015-03-03 10:50:34 UTC
When interval value is set less, then the blocksize being calculated is 0.
But block size cannot be zero
Hence returning in case of 0 block size
Comment 1 Vineeth 2015-03-03 10:51:35 UTC
Created attachment 298411 [details] [review]
fix when blocksize is 0
Comment 2 Sebastian Dröge (slomo) 2015-03-04 10:11:35 UTC
Comment on attachment 298411 [details] [review]
fix when blocksize is 0

I think we should either make that an error, or use a block_size of 1 as fallback. And maybe make the minimum value of the property a bit bigger :)
Comment 3 Vineeth 2015-03-04 10:41:33 UTC
Created attachment 298517 [details] [review]
fix when blocksize is 0

We wont be able to set minimum value of the property, since the calculation of interval_frames is dependent on rate of the audio and the interval property being set. And based on that block size is being calculated.
Since block size can not be less than 1, resetting the value to 1.
Comment 4 Vineeth 2015-04-20 08:18:36 UTC
Hi Sebastian,
    Can you please check if the changes made are proper.


Regards,
Vineeth
Comment 5 Tim-Philipp Müller 2015-04-23 23:52:59 UTC
commit 03d3d36053d05b82a76918175d1b62c15d551b0f
Author: Tim-Philipp Müller <tim@centricular.com>
Date:   Fri Apr 24 00:30:35 2015 +0100

    level: fix infinite loop for very low interval values
    
    https://bugzilla.gnome.org/show_bug.cgi?id=745515