Skip to content

Commit

Permalink
Fix crash when switching sound to simulating state while there's pref…
Browse files Browse the repository at this point in the history
…ill task active (fixes #1627)
  • Loading branch information
Xottab-DUTY committed Mar 12, 2024
1 parent 78ad33e commit 958757e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/xrSound/SoundRender_Emitter_FSM.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,16 +107,16 @@ void CSoundRender_Emitter::update(float fTime, float dt)
if (fTime >= fTimeToStop)
{
// STOP
m_current_state = stStopped;
SoundRender->i_stop(this);
m_current_state = stStopped;
}
else
{
if (!update_culling(dt))
{
// switch to: SIMULATE
m_current_state = stSimulating; // switch state
SoundRender->i_stop(this);
m_current_state = stSimulating;
}
else
{
Expand Down

0 comments on commit 958757e

Please sign in to comment.