[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdebase/runtime/phonon/xine
From: Matthias Kretz <kretz () kde ! org>
Date: 2007-12-17 18:44:31
Message-ID: 1197917071.085525.12177.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 749733 by mkretz:
When in ~XineEngine don't do any delayed destruction anymore because the
XineThread is gone (or just about to go).
BUG: 153515
M +1 -1 audioport.cpp
M +2 -0 xineengine.cpp
M +2 -0 xineengine.h
--- trunk/KDE/kdebase/runtime/phonon/xine/audioport.cpp #749732:749733
@@ -169,7 +169,7 @@
void AudioPort::waitALittleWithDying()
{
- if (d->ref == 1 && !d->dontDelete) {
+ if (d->ref == 1 && !d->dontDelete && !XineEngine::inShutdown()) {
// this is the last ref to the data, so it will get deleted in a few instructions unless
new AudioPortDeleter(d.data());
// AudioPortDeleter refs it once more
--- trunk/KDE/kdebase/runtime/phonon/xine/xineengine.cpp #749732:749733
@@ -59,6 +59,7 @@
: m_xine(xine_new()),
m_config(_config),
m_useOss(XineEngine::Unknown),
+ m_inShutdown(false),
d(new XineEnginePrivate),
m_nullPort(0),
m_nullVideoPort(0),
@@ -76,6 +77,7 @@
XineEngine::~XineEngine()
{
+ m_inShutdown = true;
/*if (m_thread) {
m_thread->stopAllStreams();
}*/
--- trunk/KDE/kdebase/runtime/phonon/xine/xineengine.h #749732:749733
@@ -86,6 +86,7 @@
static bool deinterlaceVCD();
static bool deinterlaceFile();
static int deinterlaceMethod();
+ static bool inShutdown() { return self()->m_inShutdown; }
protected:
XineEngine(const KSharedConfigPtr &cfg);
@@ -132,6 +133,7 @@
bool m_deinterlaceDVD : 1;
bool m_deinterlaceVCD : 1;
bool m_deinterlaceFile : 1;
+ bool m_inShutdown : 1;
const XineEnginePrivate *const d;
xine_audio_port_t *m_nullPort;
xine_video_port_t *m_nullVideoPort;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic