After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 719463 - Invalid null key and segmentation fault
Invalid null key and segmentation fault
Status: RESOLVED FIXED
Product: doxygen
Classification: Other
Component: general
1.8.5-GIT
Other Linux
: Normal major
: ---
Assigned To: Dimitri van Heesch
Dimitri van Heesch
Depends on:
Blocks:
 
 
Reported: 2013-11-28 05:04 UTC by Orion Poplawski
Modified: 2013-12-24 18:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Small example describing the problem (19.72 KB, application/octet-stream)
2013-12-01 19:11 UTC, albert
Details

Description Orion Poplawski 2013-11-28 05:04:49 UTC
I'm trying to build the plplot doxygen documentation on Fedora 20 with doxygen 1.8.5.  I get the following:

Building group list...
Building directory list...
Building namespace list...
QGDict::hashAsciiKey: Invalid null key
QGDict::hashAsciiKey: Invalid null key
Building file list...
Building class list...
Associating documentation with classes...
Computing nesting relations for classes...
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/bindings/java/PLCallbackCT.java:5: warning: Internal inconsistency: scope for class plplot::core::PLCallbackCT not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/bindings/java/PLCallbackLabel.java:5: warning: Internal inconsistency: scope for class plplot::core::PLCallbackLabel not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/bindings/java/PLCallbackMapform.java:5: warning: Internal inconsistency: scope for class plplot::core::PLCallbackMapform not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/bindings/java/PLStream.java:32: warning: Internal inconsistency: scope for class plplot::core::PLStream not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/fedora/bindings/java/config.java:23: warning: Internal inconsistency: scope for class plplot::core::config not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/fedora/bindings/java/PLGraphicsIn.java:11: warning: Internal inconsistency: scope for class plplot::core::PLGraphicsIn not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/fedora/bindings/java/plplotjavac.java:11: warning: Internal inconsistency: scope for class plplot::core::plplotjavac not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/fedora/bindings/java/plplotjavacConstants.java:11: warning: Internal inconsistency: scope for class plplot::core::plplotjavacConstants not found!
/export/home/orion/fedora/plplot/plplot-5.9.9-svn12479/fedora/bindings/java/plplotjavacJNI.java:11: warning: Internal inconsistency: scope for class plplot::core::plplotjavacJNI not found!
Building example list...
Searching for enumerations...
Searching for documented typedefs...
Searching for members imported via using declarations...
Searching for included using directives...
Searching for documented variables...
error: NamespaceDef::insertMembers(): member `_swig_property' with class scope `' inserted in namespace scope `plplotc'!
Building interface member list...
Building member list...
Searching for friends...
Searching for documented defines...
Computing class inheritance relations...
Computing class usage relations...

Program received signal SIGSEGV, Segmentation fault.
extractClassNameFromType (type=..., pos=@0x7fffffffd12c: 0, name=..., templSpec=..., lang=SrcLangExt_Fortran) at util.cpp:5865
5865        if (type.at(pos)==',') return -1;
(gdb) print pos
$1 = (int &) @0x7fffffffd12c: 0
(gdb) print type
$2 = (const QCString &) @0x7fffffffd130: {m_data = 0x0}
(gdb) bt
  • #0 extractClassNameFromType
    at util.cpp line 5865
  • #1 findUsedClassesForClass
    at doxygen.cpp line 4151
  • #2 findUsedTemplateInstances
    at doxygen.cpp line 4957
  • #3 parseInput
    at doxygen.cpp line 10910
  • #4 main
    at main.cpp line 37
  • #0 qWarning
    at qglobal.cpp line 410
  • #1 QGDict::hashKeyAscii
    at qgdict.cpp line 128
  • #2 QGDict::look_ascii
    at qgdict.cpp line 399
  • #3 find
    at ../qtools/qasciidict.h line 66
  • #4 find
    at sortdict.h line 238
  • #5 FileDef::addUsingDirective
    at filedef.cpp line 1110
  • #6 findUsingDirectives
    at doxygen.cpp line 1946
  • #7 findUsingDirectives
    at doxygen.cpp line 1960
  • #8 findUsingDirectives
    at doxygen.cpp line 1960
  • #9 findUsingDirectives
    at doxygen.cpp line 1960
  • #10 parseInput
    at doxygen.cpp line 10826
  • #11 main
    at main.cpp line 37
  • #5 FileDef::addUsingDirective
    at filedef.cpp line 1110
$3 = (NamespaceDef *) 0x23e72d0
(gdb) print *nd
$4 = {<Definition> = {<DefinitionIntf> = {_vptr.DefinitionIntf = 0x91a850 <vtable for NamespaceDef+16>}, m_impl = 0x23e73e0, m_name = {
      m_data = 0x23a9570 "java::io::"}, m_isSymbol = true, m_symbolName = {m_data = 0x0}, m_defLine = 1, m_defColumn = 1}, visited = false, fileName = {
    m_data = 0x23c3ca0 "namespacejava::io::"}, files = {<QList<char>> = {<QGList> = {<QCollection> = {_vptr.QCollection = 0x792c30 <vtable for QStrList+16>, 
          del_item = true}, firstNode = 0x0, lastNode = 0x0, curNode = 0x0, curIndex = -1, numNodes = 0, iterators = 0x0}, <No data fields>}, dc = true}, 
  usingDirList = 0x0, usingDeclList = 0x0, m_innerCompounds = 0x23e7610, m_allMembersDict = 0x0, m_memberLists = {<QGList> = {<QCollection> = {
        _vptr.QCollection = 0x7950d0 <vtable for QList<MemberList>+16>, del_item = false}, firstNode = 0x0, lastNode = 0x0, curNode = 0x0, curIndex = -1, 
      numNodes = 0, iterators = 0x0}, <No data fields>}, memberGroupSDict = 0x23e76d0, classSDict = 0x23e7490, namespaceSDict = 0x23e7550, m_subGrouping = true, 
  m_type = NamespaceDef::NAMESPACE, m_isPublished = false}
(gdb) print nd->qualifiedName()
$5 = {m_data = 0x0}
Comment 1 albert 2013-12-01 19:11:57 UTC
Created attachment 263245 [details]
Small example describing the problem

I've downloaded plplot version 5.9.9 adjusted the Doxyfile.in to represent my directory structure and only used as INPUT the bindings directory with its subdirectories.

With the current git version in debug mode under Cygwin I get as stack trace:
(gdb) where
  • #0 extractClassNameFromType
    at util.cpp line 5916
  • #1 findUsedClassesForClass
    at doxygen.cpp line 4158
  • #2 findUsedTemplateInstances
    at doxygen.cpp line 4964
  • #3 parseInput
    at doxygen.cpp line 10963
  • #4 main
    at main.cpp line 37

where the crash is at:
5916        if (type.at(pos)==',') return -1;
this is due to the fact that type is the null pointer.
looking in findUsedTemplateInstances reveals that type is set to the null pointer by normalizeNonTemplateArgumentsInString (and is not reset by typdef test or substitute test).

Enabling -d classes gives:
  Usage: Class plplot :
    Found variable C in class plplot

This "class" is actually a FORTRAN module plplot found in the file bindings/f95/sfstubsf95.f90 but it is also a module in d/plplot.d and this confuses doxygen.

Based on these observations it was possible to create the attached smaller example.
Comment 2 Kevin McBride 2013-12-01 19:16:37 UTC
Confirming and marking bug as described in comment 1.
Comment 3 Dimitri van Heesch 2013-12-08 14:50:52 UTC
I'll move the fortran specific section inside the "if (typeLen>0)" guard so the crash can be prevented.
Comment 4 Dimitri van Heesch 2013-12-24 18:59:46 UTC
This bug was previously marked ASSIGNED, which means it should be fixed in
doxygen version 1.8.6. Please verify if this is indeed the case. Reopen the
bug if you think it is not fixed and please include any additional information 
that you think can be relevant (preferrably in the form of a self-contained example).