commit:     8c5d1f51fa6f639d769c1682bb03d261550ae417
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Jan  9 19:59:10 2026 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Jan  9 20:50:44 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8c5d1f51

x11-misc/sddm: Add another openSUSE patch

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...dm-0.21.0_p20251101-fix-terminal-clearing.patch | 29 ++++++++++++++++++++++
 x11-misc/sddm/sddm-0.21.0_p20251101.ebuild         |  1 +
 2 files changed, 30 insertions(+)

diff --git 
a/x11-misc/sddm/files/sddm-0.21.0_p20251101-fix-terminal-clearing.patch 
b/x11-misc/sddm/files/sddm-0.21.0_p20251101-fix-terminal-clearing.patch
new file mode 100644
index 000000000000..6f4be4124aa6
--- /dev/null
+++ b/x11-misc/sddm/files/sddm-0.21.0_p20251101-fix-terminal-clearing.patch
@@ -0,0 +1,29 @@
+Source: 
https://build.opensuse.org/projects/openSUSE:Factory/packages/sddm/files/0001-Fix-terminal-clearing.patch
+
+From d021e6d191a388b0dae8b1e0eea675423b86099d Mon Sep 17 00:00:00 2001
+From: Fabian Vogt <[email protected]>
+Date: Sun, 17 Mar 2024 19:00:20 +0100
+Subject: [PATCH] Fix terminal clearing
+
+sizeof(char *) wasn't the intention there.
+---
+ src/common/VirtualTerminal.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/common/VirtualTerminal.cpp b/src/common/VirtualTerminal.cpp
+index 9c0261e..020405a 100644
+--- a/src/common/VirtualTerminal.cpp
++++ b/src/common/VirtualTerminal.cpp
+@@ -209,8 +209,8 @@ out:
+                 fd = vtFd;
+ 
+                 // Clear VT
+-                static const char *clearEscapeSequence = "\33[H\33[2J";
+-                if (write(vtFd, clearEscapeSequence, 
sizeof(clearEscapeSequence)) == -1) {
++                static const char clearEscapeSequence[] = "\33[H\33[2J";
++                if (write(vtFd, clearEscapeSequence, 
sizeof(clearEscapeSequence) - 1) == -1) {
+                     qWarning("Failed to clear VT %d: %s", vt, 
strerror(errno));
+                 }
+ 
+-- 
+2.44.0

diff --git a/x11-misc/sddm/sddm-0.21.0_p20251101.ebuild 
b/x11-misc/sddm/sddm-0.21.0_p20251101.ebuild
index 1587ddc948e0..1674ed542e50 100644
--- a/x11-misc/sddm/sddm-0.21.0_p20251101.ebuild
+++ b/x11-misc/sddm/sddm-0.21.0_p20251101.ebuild
@@ -61,6 +61,7 @@ PATCHES=(
        "${FILESDIR}/${P}-fix-restart-greeter.patch" # pending upstream
        # thx opensuse
        "${FILESDIR}/${PN}-0.21.0_p20250310-set-XAUTHLOCALHOSTNAME.patch" # bug 
913862
+       "${FILESDIR}/${P}-fix-terminal-clearing.patch"
 )
 
 pkg_setup() {

Reply via email to