GNOME Bugzilla – Bug 566925
Crash when processing /usr/include
Last modified: 2009-06-07 20:58:52 UTC
Steps to reproduce: 1. Put /usr/include in INCLUDE_PATH 2. run Doxygen Stack trace: Didn't keep the stacktrace Other information:
While processing INCLUDE_PATH, which includes /usr/include, doxygen processed /usr/include/GL which is a symlink to ../openwin/include/GL/ resolveSymlink iterates over the directories in the path, finds a symlink, reads what the symlink points to then does this if (QFileInfo(target).isRelative()) { target = QDir::cleanDirPath(prefix+"/"+target.data()); } which boils down to QDir::cleanDirPath("/usr/include/GL"+"/"+"../openwin/include/GL/") The result after a call to QDir::cleanDirPath is /usr/include/openwin/include/GL/ which doesn't exist. Instead of concatenating the relative symlink to the prefix, it ought to be concatenated to the basedir, e.g., QDir::cleanDirPath("/usr/include+"/"+"../openwin/include/GL/") I added an extra variable to save the previous state of 'prefix' each time round the loop, and put that in the call tp cleanDirPath. Looks like its got past the INCLUDE_PATH processing.
Created attachment 125948 [details] [review] patch to doxygen.cpp This fixes the issue for me
Seems to have fixed the problem for me also. Thanks Paul.
The patch that I added is probably not portable to Windows, since it assumes that the root of the symlink is "/", rather than "x:\"
Seems to solve my problem also with symlinks bad interpretation : Searching for files in directory **land/shotDefinition QDir::readDirEntries: Cannot read the directory: **land/sqc.shared/shotDefinition Segmentation fault ls -la **land lrwxrwxrwx shotDefinition -> ../sqc.shared/shotDefinition/ lrwxrwxrwx system -> ../sqc.shared/system/ try to read **land/sqc.shared/shotDefinition in place of **land/../sqc.shared/shotDefinition
Thanks for the patch Paul, I'll include it in the next subversion update.
This bug was previously marked ASSIGNED, which means it should be fixed in doxygen version 1.5.9. Please verify if this is indeed the case and reopen the bug if you think it is not fixed (include any additional information that you think can be relevant).