comparison audio/AudioCallbackPlaySource.cpp @ 713:ce698f8d0831

Avoid floating-point exception when stopping after models deleted
author Chris Cannam
date Fri, 11 Oct 2019 13:40:54 +0100
parents e0b0f3e163ca
children 497d80d3b9c4
comparison
equal deleted inserted replaced
712:8e9702c0b9c7 713:ce698f8d0831
544 544
545 m_condition.wakeAll(); 545 m_condition.wakeAll();
546 m_lastRetrievalTimestamp = 0; 546 m_lastRetrievalTimestamp = 0;
547 if (changed) { 547 if (changed) {
548 emit playStatusChanged(m_playing); 548 emit playStatusChanged(m_playing);
549 emit activity(tr("Stop at %1").arg 549 if (m_sourceSampleRate) {
550 (RealTime::frame2RealTime 550 emit activity(tr("Stop at %1").arg
551 (m_lastCurrentFrame, m_sourceSampleRate).toText().c_str())); 551 (RealTime::frame2RealTime
552 (m_lastCurrentFrame, m_sourceSampleRate)
553 .toText().c_str()));
554 } else {
555 emit activity(tr("Stop"));
556 }
552 } 557 }
553 m_lastCurrentFrame = 0; 558 m_lastCurrentFrame = 0;
554 } 559 }
555 560
556 void 561 void