diff options
author | Uwe Klotz <uklotz@mixxx.org> | 2020-06-06 10:19:51 +0200 |
---|---|---|
committer | Uwe Klotz <uklotz@mixxx.org> | 2020-06-06 10:19:51 +0200 |
commit | 53873ee735b7cf8e9316a554b2bc67af3431839c (patch) | |
tree | bb68c217a276d19eacc79cf6add39b328a8bc222 /src/util | |
parent | 8d413b583ee06f4aec9cea1a3ce592df1a2ce0df (diff) | |
parent | 1f3fc6e97bf7a46c531aaa1ffa83010955ab6404 (diff) |
Merge branch '2.3' of git@github.com:mixxxdj/mixxx.git
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/duration.cpp | 3 | ||||
-rw-r--r-- | src/util/samplebuffer.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/util/duration.cpp b/src/util/duration.cpp index 17e1d25383..5189447b92 100644 --- a/src/util/duration.cpp +++ b/src/util/duration.cpp @@ -27,7 +27,8 @@ QChar DurationBase::kDecimalSeparator = QChar(0x002E); // static QString DurationBase::formatTime(double dSeconds, Precision precision) { if (dSeconds < 0.0 || !isfinite(dSeconds) - || dSeconds > std::numeric_limits<qint64>::max()) { + // Use >= instead of >: 2^63-1 (qint64) is rounded to 2^63 (double) + || dSeconds >= static_cast<double>(std::numeric_limits<qint64>::max())) { // negative durations and infinity or isNaN values are not supported return kInvalidDurationString; } diff --git a/src/util/samplebuffer.h b/src/util/samplebuffer.h index beb63d8bc3..d7ecebd64d 100644 --- a/src/util/samplebuffer.h +++ b/src/util/samplebuffer.h @@ -31,7 +31,7 @@ namespace mixxx { // ... // SampleBuffer(newSize).swap(sampleBuffer); // -class SampleBuffer { +class SampleBuffer final { public: SampleBuffer() : m_data(nullptr), |