git: d071b0f7dbf0 - 2026Q3 - comms/inspectrum: fix build on 32 bit platforms
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 26 Jul 2026 16:10:55 UTC
The branch 2026Q3 has been updated by fuz:
URL: https://cgit.FreeBSD.org/ports/commit/?id=d071b0f7dbf0e5233334e3e46f66f401589080b2
commit d071b0f7dbf0e5233334e3e46f66f401589080b2
Author: Robert Clausecker <fuz@FreeBSD.org>
AuthorDate: 2026-07-21 08:45:46 +0000
Commit: Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2026-07-26 16:10:42 +0000
comms/inspectrum: fix build on 32 bit platforms
On such platforms size_t is int, not long, causing confusion in
std::max().
Approved by: portmgr (build fix blanket)
MFH: 2026Q3
(cherry picked from commit 22693405a70f71c8c494a05c340b26cb1006a7cb)
---
comms/inspectrum/files/patch-src_traceplot.cpp | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/comms/inspectrum/files/patch-src_traceplot.cpp b/comms/inspectrum/files/patch-src_traceplot.cpp
new file mode 100644
index 000000000000..4e1281dc8440
--- /dev/null
+++ b/comms/inspectrum/files/patch-src_traceplot.cpp
@@ -0,0 +1,11 @@
+--- src/traceplot.cpp.orig 2026-07-21 08:44:18 UTC
++++ src/traceplot.cpp
+@@ -32,7 +32,7 @@ void TracePlot::paintMid(QPainter &painter, QRect &rec
+ {
+ if (sampleRange.length() == 0) return;
+
+- int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
++ int samplesPerColumn = std::max(static_cast<size_t>(1), sampleRange.length() / rect.width());
+ int samplesPerTile = tileWidth * samplesPerColumn;
+ size_t tileID = sampleRange.minimum / samplesPerTile;
+ size_t tileOffset = sampleRange.minimum % samplesPerTile; // Number of samples to skip from first image tile