Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
None
-
None
-
Windows 7 64-bit
-
7feed7318b3ca52d56cb6eb8f11233f32bdcae09
Description
Under certain conditions, QtCreator crashes when deleting files from a Qt project.
Steps to reproduce:
1. Create a new Qt Gui project
2. Add a new file to it (test_win32.cpp)
3. Modify the project file, by removing test_win32.cpp from the SOURCES variable, and instead include the following line at the bottom of the file:
win32:SOURCES += test_win32.cpp
4. Try removing mainwindow.cpp from the project
The cause of the crash seems to be the mis-handling of line-number detection for one-liner branches (like win32:SOURCES += ...).
The crash occurs, because the project file writer detects the branch @ line 0, since it discards the current line number when recursively detecting variables within the branch, although no more line-number tokens precede the actual assignment, thus leading to line number 0.
Please see merge request #2168 for my fix.