public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Gwyn Ciesla <gwync@protonmail.com>
To: git-commits@fedoraproject.org
Subject: [rpms/monsterz] f45: Patch for integer overflow
Date: Tue, 20 Oct 2026 15:22:04 GMT	[thread overview]
Message-ID: <179250972417.1.7836253520064084189.rpms-monsterz-03cae141a39c@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/monsterz
Branch : f45
Commit : 03cae141a39c5f5ff450e3eeb04d52340f9823aa
Author : Gwyn Ciesla <gwync@protonmail.com>
Date   : 2026-10-20T10:21:17-05:00
Stats  : +17/-1 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/monsterz/c/03cae141a39c5f5ff450e3eeb04d52340f9823aa?branch=f45

Log:
Patch for integer overflow

---
diff --git a/intoverflow.patch b/intoverflow.patch
new file mode 100644
index 0000000..a721691
--- /dev/null
+++ b/intoverflow.patch
@@ -0,0 +1,11 @@
+--- monsterz.py~	2026-10-19 15:41:23.509147405 -0500
++++ monsterz.py	2026-10-19 16:04:08.514041187 -0500
+@@ -108,7 +108,7 @@
+                 r, g, b = p
+                 M = int(max(r, g, b))
+                 m = int(min(r, g, b))
+-                val = (2 * M + r + g + b) // 5
++                val = (2 * M + int(r) + int(g) + int(b)) // 5
+                 if sys.maxsize > 2**32 : p[:] = (val + r) / 2, (val + g) / 2, (val + b) / 2
+                 if alpha[y][x] >= 250:
+                     alpha[y][x] = 255 - (M - m) * 3 // 4

diff --git a/monsterz.spec b/monsterz.spec
index 9da3fe1..182695e 100644
--- a/monsterz.spec
+++ b/monsterz.spec
@@ -1,6 +1,6 @@
 Name:           monsterz
 Version:        0.7.1
-Release:        41%{?dist}
+Release:        42%{?dist}
 Summary:        Puzzle game, similar to Bejeweled or Zookeeper
 License:        WTFPL
 URL:            http://sam.zoy.org/monsterz/
@@ -10,6 +10,7 @@ Patch0:         %{name}-0.7.1-userpmopts.patch
 Patch1:         %{name}-0.7.1-64bitfix.patch
 Patch2:         %{name}-0.7.1-blit-crash.patch
 Patch3:         %{name}-0.7.1-py3.patch
+Patch4:         intoverflow.patch
 BuildRequires: make
 BuildRequires:  gcc
 BuildRequires:  desktop-file-utils
@@ -34,6 +35,7 @@ board again. Chain reactions earn you even more points.
 %patch -P1 -p1
 %patch -P2 -p0
 %patch -P3 -p1
+%patch -P4 -p0
 %py3_shebang_fix .
 
 %build
@@ -86,6 +88,9 @@ install -pm0644 graphics/icon.png %{buildroot}%{_datadir}/icons/hicolor/64x64/ap
 
 
 %changelog
+* Mon Oct 19 2026 Gwyn Ciesla <gwync@protonmail.com> - 0.7.1-42
+- Patch for integer overflow
+
 * Thu Jul 16 2026 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.1-41
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild
 

                 reply	other threads:[~2026-10-20 15:22 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=179250972417.1.7836253520064084189.rpms-monsterz-03cae141a39c@fedoraproject.org \
    --to=gwync@protonmail.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox