Commit 2a999767 authored by Nicolas Fella's avatar Nicolas Fella
Browse files

Port to std::sort

Summary: qsort is deprecated

Reviewers: #plasma, apol

Reviewed By: apol

Subscribers: broulik, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D25672
parent 9a2bbcf3
......@@ -26,6 +26,7 @@
#include <KLocalizedString>
#include <algorithm>
#include <sys/utsname.h>
#ifdef Q_OS_FREEBSD
......@@ -173,7 +174,7 @@ void BacklightHelper::initUsingSysctl()
}
free(levels);
// Sorting helps when finding max value and when scanning for the nearest level in setbrightness().
qSort(m_sysctlBrightnessLevels.begin(), m_sysctlBrightnessLevels.end());
std::sort(m_sysctlBrightnessLevels.begin(), m_sysctlBrightnessLevels.end());
#endif
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment