Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.1.1
-
None
-
Debian GNU/Linux jessie/sid
-
b5ef81eca1a4f1b803a8a2b2d8eb66bc64faa678
Description
I get this crash when building documentation of ubuntu-ui-toolkit with qdoc 5.1.1:
#0 CppCodeMarker::qmlSections (this=0xbffff030, qmlClassNode=0x8223e90, style=CodeMarker::Subpage) at cppcodemarker.cpp:1298 #1 0x080e4a36 in HtmlGenerator::generateAllQmlMembersFile (this=0xbffff14c, qml_cn=qml_cn@entry=0x8223e90, marker=0xbffff030) at htmlgenerator.cpp:2074 #2 0x080ea022 in HtmlGenerator::generateDocNode (this=0xbffff14c, dn=0x8223e90, marker=<optimized out>) at htmlgenerator.cpp:1519 #3 0x080c30c0 in Generator::generateInnerNode (this=0xbffff14c, node=0x8223e90) at generator.cpp:972 #4 0x080c2f9d in Generator::generateInnerNode (this=0xbffff14c, node=0x81b61d4) at generator.cpp:981 #5 0x080bea8c in Generator::generateTree (this=this@entry=0xbffff14c) at generator.cpp:1335 #6 0x080f8315 in HtmlGenerator::generateTree (this=0xbffff14c) at htmlgenerator.cpp:254 #7 0x08100c20 in processQdocconfFile (fileName=...) at main.cpp:483 #8 0x0804fe7d in main (argc=2, argv=0xbffff394) at main.cpp:634
Line 1298 is:
classMap->second.insert(key,*c);
The crash happens because classMap is never initialized if the first type is abstract:
ClassMap* classMap = 0; <...> if (!current->isAbstract()) { classMap = new ClassMap; classMap->first = current; all.classMapList_.append(classMap); }
This bug was introduced in commit 04770e5824.