Make JS sound objects only self-destruct when fading to 0
This was SVN commit r7491.
This commit is contained in:
parent
4fe991074f
commit
49574953b8
@ -121,7 +121,8 @@ bool JSI_Sound::Fade(JSContext* cx, uintN argc, jsval* argv)
|
||||
// called from the dtor. solution is to neuter our Handle by
|
||||
// setting it to 0 (ok since it'll be freed). this does mean that
|
||||
// no further operations can be carried out during that final fade.
|
||||
m_Handle = 0;
|
||||
if (final_gain == 0.0f)
|
||||
m_Handle = 0;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user