Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
6.0.0 RC
-
None
-
db481c15ec177b1b1db3d48d0c4e128a59a20946 (qt/qttools/dev)
Description
The parsejava test case fails, as due to a premature exit of lupdate the "good" project.ts file is not generated.
Running lupdate on qttools/tests/auto/linguist/lupdate/testdata/good/parsejava/project.pro file prints:
$ dev-build/qtbase/bin/lupdate dev/qttools/tests/auto/linguist/lupdate/testdata/good/parsejava/project.pro
ASSERT: "rc <= 0xffff" in file qtbase/include/QtCore/../../../../dev/qtbase/src/corelib/text/qchar.h, line 114
(same when running lupdate-pro)
This is the stack trace:
frame #6: 0x00000001006e45ec libQt6Core_debug.6.dylib`QChar::QChar(this=0x00007ffeefbfd8b0, rc=4294967295) at qchar.cpp:641:9 frame #7: 0x00000001006e47cb libQt6Core_debug.6.dylib`QChar::QChar(this=0x00007ffeefbfd8b0, rc=4294967295) at qchar.cpp:639:1 frame #8: 0x000000010000eedb lupdate`QChar::QChar(this=0x00007ffeefbfd8b0, rc=-1) at qchar.h:116:51 frame #9: 0x00000001000992de lupdate`getToken() at java.cpp:121:20 frame #10: 0x0000000100097f17 lupdate`parse(tor=0x00007ffeefbfdf50, cd=0x00007ffeefbfe098) at java.cpp:452:13 frame #11: 0x0000000100097de2 lupdate`loadJava(translator=0x00007ffeefbfdf50, filename=0x0000000101b0b890, cd=0x00007ffeefbfe098) at java.cpp:607:5 frame #12: 0x00000001000a2a77 lupdate`processSources(fetchedTor=0x00007ffeefbfdf50, sourceFiles=0x00007ffeefbfe1b0, cd=0x00007ffeefbfe098, fail=0x00007ffeefbfe757) at main.cpp:506:13 frame #13: 0x00000001000aa0c9 lupdate`ProjectProcessor::processProject(this=0x00007ffeefbfe4d8, options=(i = 113), prj=0x0000000101b0adf0, topLevel=true, nestComplain=false, parentTor=0x0000000000000000, fail=0x00007ffeefbfe757) const at main.cpp:634:13 frame #14: 0x00000001000a3e0a lupdate`ProjectProcessor::processProjects(this=0x00007ffeefbfe4d8, topLevel=true, options=(i = 113), projects=size=1, nestComplain=false, parentTor=0x0000000000000000, fail=0x00007ffeefbfe757) const at main.cpp:577:13 frame #15: 0x00000001000a15ac lupdate`main(argc=3, argv=0x00007ffeefbff6c0) at main.cpp:1062:30
In the Java parser, the code regularly creates a QChar(EOF), and EOF is -1:
http://www.cplusplus.com/reference/cstdio/EOF/
This is building qtbase and qttools from dev:HEAD, so it's not a missing dependency update. And commit 6f3c749f0e85c0bfd93a6d176fce2f25edf58962 (fix for https://bugreports.qt.io/browse/QTBUG-88647) is already merged and part of the build.
Attachments
Issue Links
- is duplicated by
-
QTBUG-88948 tst_lupdate::good(parsejava) '!proc.exitCode()' returned FALSE.
-
- Closed
-
- relates to
-
QTBUG-88647 Qt6: lupdate crashes when building Qt translations
-
- Closed
-