You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There can be a case when fading in/out will never resolve.
Inside _startFadeInterval method vol is first clamped to the to value, and then is rounded:
// Make sure the volume is in the right bounds.if(diff<0){vol=Math.max(to,vol);}else{vol=Math.min(to,vol);}// Round to within 2 decimal points.vol=Math.round(vol*100)/100;
In case to is a float like 0.901, then vol might first be assigned with 0.901, and then rounded to 0.9. After that the vol >= to check would fail, and runtime would fall into infinite loop.
I assume this could be fixed by moving rounding higher above the clamping part.
The text was updated successfully, but these errors were encountered:
There can be a case when fading in/out will never resolve.
Inside
_startFadeInterval
methodvol
is first clamped to theto
value, and then is rounded:In case
to
is a float like0.901
, thenvol
might first be assigned with0.901
, and then rounded to0.9
. After that thevol >= to
check would fail, and runtime would fall into infinite loop.I assume this could be fixed by moving rounding higher above the clamping part.
The text was updated successfully, but these errors were encountered: