summaryrefslogtreecommitdiffstats
path: root/src/doxygen.cpp
diff options
context:
space:
mode:
authorDimitri van Heesch <doxygen@gmail.com>2020-04-06 20:58:51 (GMT)
committerDimitri van Heesch <doxygen@gmail.com>2020-04-06 20:58:51 (GMT)
commit7ea3bb2e16facf7befa820e4f1ce43872d335554 (patch)
treeb605af675df6aaa069979cb3f91813e1d912b8cd /src/doxygen.cpp
parent6511573f661d3f8eacc6d316222fd77b98720d6a (diff)
downloadDoxygen-7ea3bb2e16facf7befa820e4f1ce43872d335554.zip
Doxygen-7ea3bb2e16facf7befa820e4f1ce43872d335554.tar.gz
Doxygen-7ea3bb2e16facf7befa820e4f1ce43872d335554.tar.bz2
Fixing issues with wrong use of std::sort
Diffstat (limited to 'src/doxygen.cpp')
-rw-r--r--src/doxygen.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/doxygen.cpp b/src/doxygen.cpp
index e766dd5..cabc5ce 100644
--- a/src/doxygen.cpp
+++ b/src/doxygen.cpp
@@ -9061,7 +9061,7 @@ static void generateDiskNames()
std::sort(fileEntries.begin(),
fileEntries.end(),
[](const FileEntry &fe1,const FileEntry &fe2)
- { return qstrcmp(fe1.path.data(),fe2.path.data()); }
+ { return qstrcmp(fe1.path.data(),fe2.path.data())<0; }
);
// since the entries are sorted, the common prefix of the whole array is same
@@ -10715,12 +10715,13 @@ void searchInputFiles()
}
s=inputList.next();
}
- std::sort(Doxygen::inputNameLinkedMap->begin(),Doxygen::inputNameLinkedMap->end(),
- [](FileNameLinkedMap::Ptr &f1,FileNameLinkedMap::Ptr &f2)
+ std::sort(Doxygen::inputNameLinkedMap->begin(),
+ Doxygen::inputNameLinkedMap->end(),
+ [](const auto &f1,const auto &f2)
{
return Config_getBool(FULL_PATH_NAMES) ?
- qstricmp(f1->fullName(),f2->fullName()) :
- qstricmp(f1->fileName(),f2->fileName());
+ qstricmp(f1->fullName(),f2->fullName())<0 :
+ qstricmp(f1->fileName(),f2->fileName())<0;
});
g_s.end();