Bug#1995: [21:53,19.09.99]
Armin L. Schneider
armin at uumail.de.uu.net
Sun Sep 19 20:07:29 UTC 1999
Package: kdevelop
Version: 1.0-19990828
Severity: normal
Bugreport ID : 21:53,19.09.99
Originator : Armin L. Schneider
E-Mail : armin at mingotronic.de
Subject :
Error Class : software bug
Error Location: project management
Priority : medium
Bug Description ---------------------------
2 problems when using '++' in a project path (e.g. /home/armin/C++/Quarto/kquarto)
If you want to add an existing file to your project, you end up in an infinite loop
and you have to kill kdevelop.
If you create dialogs, no sourcecode will be generated, only the
kdevdlg-file.
How to repeat the error -------------------
Create a project in a path containing '++'. Create a normal KDE application and
try to add an existing file. Be prepared to kill kdevelop...
Try to create a small dialog using the dialog editor. Then create
the sourcecode for it. No files will be generated!
Bugfix or Workaround ----------------------
The reason for both problems is the same:
a QRegExp-replace to remove the current project directory
from a pathname.
Solution:
1. in 'kdevelop/kdevelop/ckdevelop_project.cpp', replace
rel_name.replace(QRegExp(prj->getProjectDir()),"");
with
if(rel_name.find(prj->getProjectDir()) == 0)
rel_name.remove (0, strlen (prj->getProjectDir ()));
2. in 'kdevelop/kdevelop/kdlgedit/kdlgedit.cpp' replace
abs_filename.replace(QRegExp(prj->getProjectDir()),"");
with
if(abs_filename.find(prj->getProjectDir()) == 0)
abs_filename.remove (0, strlen (prj->getProjectDir ()));
Have fun,
Armin.
System Information ------------------------
KDevelop version : 1.0-19990828
KDE version : 1.1.1
QT version : 1.44
OS/Distribution : SuSE Linux 6.1
Compiler : gcc version egcs-2.91.66 19990314 (egcs-1.1.2 release)
More information about the KDevelop-devel
mailing list