diff options
author | albert-github <albert.tests@gmail.com> | 2019-11-25 10:28:45 (GMT) |
---|---|---|
committer | albert-github <albert.tests@gmail.com> | 2019-11-25 10:28:45 (GMT) |
commit | b007be7c1671661f31f056b7b7b5f480279ddbd6 (patch) | |
tree | 36746c5e031a8142a489667eea2b3d962aac7874 /src/doxygen.cpp | |
parent | dc20493b3351d79024f2f808d16f47a502346606 (diff) | |
download | Doxygen-b007be7c1671661f31f056b7b7b5f480279ddbd6.zip Doxygen-b007be7c1671661f31f056b7b7b5f480279ddbd6.tar.gz Doxygen-b007be7c1671661f31f056b7b7b5f480279ddbd6.tar.bz2 |
Checking of right usage of configuration list items
In case of a configuration list item has an equal sign in it ('=') some extra restriction are imposed / made more understandable.
Diffstat (limited to 'src/doxygen.cpp')
-rw-r--r-- | src/doxygen.cpp | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/src/doxygen.cpp b/src/doxygen.cpp index d4d55e7..3b37567 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -9209,6 +9209,7 @@ static void readTagFile(const std::unique_ptr<Entry> &root,const char *tl) { fileName = tagLine.left(eqPos).stripWhiteSpace(); destName = tagLine.right(tagLine.length()-eqPos-1).stripWhiteSpace(); + if (fileName.isEmpty() || destName.isEmpty()) return; QFileInfo fi(fileName); Doxygen::tagDestinationDict.insert(fi.absFilePath().utf8(),new QCString(destName)); //printf("insert tagDestination %s->%s\n",fi.fileName().data(),destName.data()); @@ -10689,11 +10690,22 @@ void adjustConfiguration() while (mapping) { QCString mapStr = mapping; - int i; - if ((i=mapStr.find('='))!=-1) + int i=mapStr.find('='); + if (i==-1) + { + mapping = extMaps.next(); + continue; + } + else { - QCString ext=mapStr.left(i).stripWhiteSpace().lower(); - QCString language=mapStr.mid(i+1).stripWhiteSpace().lower(); + QCString ext = mapStr.left(i).stripWhiteSpace().lower(); + QCString language = mapStr.mid(i+1).stripWhiteSpace().lower(); + if (ext.isEmpty() || language.isEmpty()) + { + mapping = extMaps.next(); + continue; + } + if (!updateLanguageMapping(ext,language)) { err("Failed to map file extension '%s' to unsupported language '%s'.\n" @@ -10709,7 +10721,6 @@ void adjustConfiguration() mapping = extMaps.next(); } - // add predefined macro name to a dictionary QStrList &expandAsDefinedList =Config_getList(EXPAND_AS_DEFINED); s=expandAsDefinedList.first(); |