Skip to content

Commit

Permalink
cpdetect: use stable sort when sorting detection results
Browse files Browse the repository at this point in the history
  • Loading branch information
mbandzi committed Apr 1, 2018
1 parent ae9a6d4 commit ce25b14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cpdetect/compiler_detector/compiler_detector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,7 @@ ReturnCode CompilerDetector::getAllCompilers()
{
const auto status = getAllSignatures();
getAllHeuristics();
std::sort(toolInfo.detectedTools.begin(), toolInfo.detectedTools.end(), compareForSort);
std::stable_sort(toolInfo.detectedTools.begin(), toolInfo.detectedTools.end(), compareForSort);
removeUnusedCompilers();
if (toolInfo.detectedLanguages.empty())
{
Expand Down

0 comments on commit ce25b14

Please sign in to comment.