]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - glsdk/gstreamer0-10.git/commit
queue2: avoid crashing due to negative percent
authorThiago Santos <thiago.sousa.santos@collabora.co.uk>
Tue, 10 Nov 2009 13:10:56 +0000 (10:10 -0300)
committerThiago Santos <thiago.sousa.santos@collabora.co.uk>
Tue, 10 Nov 2009 13:10:56 +0000 (10:10 -0300)
commit245089c9bd788ba11cc6828ed647d57fa851dce1
treedfa388452aa6ba778a05d16c2ec93f7f83b5bbc2
parent5c7104c0023161131a54d39f09b4635b0241f681
queue2: avoid crashing due to negative percent

queue2 would crash when using small buffer sizes because
it would overflow when calculating the percentage, resulting
in the buffering GstMessage not being created and trying to be
used. This patch uses a gint64 instead of a gint to do the
percentage math, making it harder to overflow.
plugins/elements/gstqueue2.c