BMediaEventLooper::SetBufferDuration: Clamp if negative

* For the sake of making the code more backward compatible,
and safer eventually.
This commit is contained in:
Dario Casalinuovo
2016-05-07 22:23:28 +02:00
parent 6d63bc5e60
commit b18c444994
+4
View File
@@ -417,6 +417,10 @@ void
BMediaEventLooper::SetBufferDuration(bigtime_t duration)
{
CALLED();
if (duration < 0)
duration = 0;
fBufferDuration = duration;
}