KDevelop hangs in termination

Kevin Gilbert kev.gilbert at cdu.edu.au
Fri Nov 18 02:35:21 UTC 2005


Hi,

For a while now KDevelop hangs on termination. I am not sure with what release it started and it could have something to do with the version of GCC that I am running. Current version details are:

gcc --version
gcc (GCC) 4.1.0 20051114 (experimental)

kdevelop --version
Qt: 3.3.4
KDE: 3.5 (RC1)
KDevelop: 3.3
(but note that this is compiled from SVN sources)

I have tracked the problem down to the termination code of the CPP background parser and have developed the following patch to overcome the hang.

--- kdevelop-3.3.0/languages/cpp/backgroundparser.cpp   2005-09-10 17:52:36.000000000 +0930
+++ /usr/local/src/kde/kde-svn/kdevelop/languages/cpp/backgroundparser.cpp      2005-11-18 10:39:47.000000000 +0930
@@ -347,9 +347,6 @@
        QMutexLocker locker( &m_mutex );
        m_close = true;
        m_canParse.wakeAll();
-
-       while ( running() )
-               sleep( 1 );
 }

 bool BackgroundParser::filesInQueue()
@@ -398,8 +395,6 @@
        }

        kdDebug( 9007 ) << "!!!!!!!!!!!!!!!!!! BG PARSER DESTROYED !!!!!!!!!!!!" << endl;
-
-       QThread::exit();
 }

 //kate: indent-mode csands; tab-width 4; space-indent off;
--- kdevelop-3.3.0/languages/cpp/cppsupportpart.cpp     2005-10-11 00:30:20.000000000 +0930
+++ /usr/local/src/kde/kde-svn/kdevelop/languages/cpp/cppsupportpart.cpp        2005-11-18 10:39:55.000000000 +0930
@@ -248,7 +248,7 @@
        if ( m_backgroundParser )
        {
                m_backgroundParser->close();
-               //      m_backgroundParser->wait();
+               m_backgroundParser->wait();
                delete m_backgroundParser;
                m_backgroundParser = 0;
        }

==========

Cheers,

Kevin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20051118/c8c7ef6c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 307 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20051118/c8c7ef6c/attachment.sig>


More information about the KDevelop-devel mailing list