Version: 3.0 alpha 5 (using KDE KDE 3.1.1) Installed from: Compiled From Sources Compiler: gcc 3.2.2 OS: Linux Gideon crashes on an attempt to parse a long fortran source file at startup. Fortran project is created normally, then fortran source file is added to the project. All works fine, but the next time I start gideon - it crashes. Messages: kdevelop (fortran support): maybe parse <file name> kde trace: 0x414b4f29 in wait4 () from /lib/libc.so.6 #0 0x414b4f29 in wait4 () from /lib/libc.so.6 #1 0x41535234 in sys_sigabbrev () from /lib/libc.so.6 #2 0x412cb103 in waitpid () from /lib/libpthread.so.0 #3 0x40a2bc4d in KCrash::defaultCrashHandler(int) () from /opt/kde/lib/libkdecore.so.4 #4 0x41430b48 in sigaction () from /lib/libc.so.6 #5 0x414c48d8 in regexec () from /lib/libc.so.6 #6 0x40a37043 in KRegExpPrivate::match(char const*) () from /opt/kde/lib/libkdecore.so.4 #7 0x40a373b8 in KRegExp::match(char const*) () from /opt/kde/lib/libkdecore.so.4 #8 0x4202ed37 in FixedFormParser::process(QCString const&, QString const&, int) () from /opt/kde/lib/kde3/libkdevfortransupport.so #9 0x4202f11f in FixedFormParser::parse(QString const&) () from /opt/kde/lib/kde3/libkdevfortransupport.so #10 0x4202d1bd in FortranSupportPart::maybeParse(QString) () from /opt/kde/lib/kde3/libkdevfortransupport.so #11 0x4202d42c in FortranSupportPart::initialParse() () from /opt/kde/lib/kde3/libkdevfortransupport.so #12 0x4202e091 in FortranSupportPart::qt_invoke(int, QUObject*) () from /opt/kde/lib/kde3/libkdevfortransupport.so #13 0x40da7939 in QObject::activate_signal(QConnectionList*, QUObject*) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #14 0x410848b2 in QSignal::signal(QVariant const&) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #15 0x40dc1af8 in QSignal::activate() () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #16 0x40dc8a93 in QSingleShotTimer::event(QEvent*) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #17 0x40d498f4 in QApplication::internalNotify(QObject*, QEvent*) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #18 0x40d494e9 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #19 0x409b0c69 in KApplication::notify(QObject*, QEvent*) () from /opt/kde/lib/libkdecore.so.4 #20 0x40d247a3 in QEventLoop::activateTimers() () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #21 0x40d022b8 in QEventLoop::processEvents(unsigned) () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #22 0x40d5d6e6 in QEventLoop::enterLoop() () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #23 0x40d5d588 in QEventLoop::exec() () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #24 0x40d49b21 in QApplication::exec() () from /usr/lib/qt-3.1.1/lib/libqt-mt.so.3 #25 0x0806961c in main () #26 0x4141cbb4 in __libc_start_main () from /lib/libc.so.6
Can you retest with CVS HEAD?
*** Bug 69433 has been marked as a duplicate of this bug. ***
Re: Can you retest with CVS HEAD? Have not done it yet, but tried beta 1 of kdevelop - same problem.
*** Bug 76273 has been marked as a duplicate of this bug. ***
Tried the same trick with 3.0.2: Platform: Slackware 9.1/gcc 3.2.3 Installed from contributed tgz package Crash when I try to add the following fortran file an empty fortran project: c interface for xns inibs SUBROUTINE XNS_INIB(NG,X,Y,Z, USB,IE,JE,KE) INCLUDE 'xcominc3.f' INCLUDE 'block.f' real, dimension (0:IE,0:JE,0:KE,NBLO) :: X,Y,Z real, dimension (0:JE,0:KE,NBLO) :: USB print *,"I2D = ",i2d if(i2d.eq.0) then print *, "Initializing 3D" call XNS_INIB3D(NG,X,Y,Z, USB,IE,JE,KE) else print *, "Initializing 2D" call XNS_INIB2D(NG,X,Y,Z, USB,IE,JE,KE) end if return end :(
Fixed in CVS.
CVS commit by dagerbo: Use QRegExp instead of the deprecated KRegExp. Hopefully fixing a few crashes in the process.. CCMAIL: 63973@bugs.kde.org M +12 -10 fixedformparser.cpp 1.11.2.1 M +2 -2 fixedformparser.h 1.3.2.1 --- kdevelop/languages/fortran/fixedformparser.cpp #1.11:1.11.2.1 @@ -22,7 +22,10 @@ FixedFormParser::FixedFormParser(CodeMod m_model = model; - functionre.compile("(integer|real|logical|complex|character|" + functionre.setPattern("(integer|real|logical|complex|character|" "double(precision)?)function([^(]+).*"); - subroutinere.compile("subroutine([^(]+).*"); + subroutinere.setPattern("subroutine([^(]+).*"); + + functionre.setCaseSensitive( false ); + subroutinere.setCaseSensitive( false ); } @@ -30,7 +33,4 @@ FixedFormParser::FixedFormParser(CodeMod void FixedFormParser::process(const QCString &line, const QString &fileName, int lineNum) { - if (line.isEmpty()) - return; - QCString simplified; int l = line.length(); @@ -39,9 +39,11 @@ void FixedFormParser::process(const QCSt simplified += line[i]; - QCString name; - if (functionre.match(simplified)) - name = functionre.group(3); - else if (subroutinere.match(simplified)) - name = subroutinere.group(1); + if ( simplified.isEmpty() ) return; + + QString name; + if (functionre.search(simplified) != -1) + name = functionre.cap(3); + else if (subroutinere.search(simplified) != -1) + name = subroutinere.cap(1); else return; --- kdevelop/languages/fortran/fixedformparser.h #1.3:1.3.2.1 @@ -15,5 +15,5 @@ #include <qstring.h> #include <qtextstream.h> -#include <kregexp.h> +#include <qregexp.h> #include <codemodel.h> @@ -30,5 +30,5 @@ private: CodeModel* m_model; FileDom m_file; - KRegExp functionre, subroutinere; + QRegExp functionre, subroutinere; };