Local patches for ScrollZ (IRC client, ircII fork) on Arch Linux. Both fixes are also submitted upstream:
| Patch | Upstream PR | What it does |
|---|---|---|
fix-fortify-snprintf.patch |
#33 | Fixes *** buffer overflow detected ***: terminated on every channel join. Two snprintf(&buf[strlen(buf)], sizeof(buf), …) calls in parse.c pass the full buffer size instead of the remaining space; glibc's _FORTIFY_SOURCE=3 (Arch default with gcc 14+) catches it and aborts. |
fix-mirc-256color.patch |
#34 | Replaces the 8-colour-ANSI mIRC translation table in edit6.c with xterm-256 escapes so each mIRC colour maps to a reasonable sRGB approximation (e.g. mIRC 7 = orange instead of cyan). Also fixes a bounds-check bug that silently dropped bg=0 and bg=15. |
The bundled PKGBUILD is a copy of the upstream scrollz-git AUR package with both patches wired into prepare():
mkdir -p ~/scrollz-build
cp PKGBUILD fix-fortify-snprintf.patch fix-mirc-256color.patch ~/scrollz-build/
cd ~/scrollz-build
makepkg -siOr with yay:
yay -G scrollz-git
cd scrollz-git
cp /path/to/scrollz-patches/* .
makepkg -sigit clone https://github.com/ScrollZ/ScrollZ.git
cd ScrollZ
patch -p1 -i /path/to/fix-fortify-snprintf.patch
patch -p1 -i /path/to/fix-mirc-256color.patch
./configure --prefix=/usr --enable-regexp --enable-fish --with-openssl
make