Commit e1ad60f0 authored by Tim Jansen's avatar Tim Jansen

Don't stop the pipe when somebody else already restarted it. This fixes another race condition

svn path=/trunk/kdemultimedia/juk/; revision=214337
parent 026d426f
......@@ -156,7 +156,12 @@ void GStreamerPlayer::setupPlayer()
SLOT(slotSetPosition(long long)));
connect(m_player, SIGNAL(streamLength(long long)),
SLOT(slotSetDuration(long long)));
connect(m_player, SIGNAL(streamEnd()), SLOT(stop()));
connect(m_player, SIGNAL(streamEnd()), SLOT(stopIfNotPlaying()));
}
void GStreamerPlayer::stopIfNotPlaying() {
if (!playing())
stop();
}
#include "gstreamerplayer.moc"
......
......@@ -61,6 +61,7 @@ public slots:
private slots:
void slotSetPosition(long long d) { m_positionNs = d; }
void slotSetDuration(long long d) { m_durationNs = d; }
void stopIfNotPlaying();
private:
void setupPlayer();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment