From e183b62e42f49fa297b5667a82199c7e76fc0a81 Mon Sep 17 00:00:00 2001 From: Olivier Fourdan Date: Wed, 15 Jan 2025 09:40:34 +0100 Subject: [PATCH] os/connection: Make sure partial is initialized Following the change in Xtrans 1.5 that allows for partial connections to succeed, we need to make sure partial is properly initialized at first, otherwise we rely on an uninitialized variable. Signed-off-by: Olivier Fourdan Suggested-by: Twaik Yont Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1783 (cherry picked from commit 080fb49eff4de7ec3a29214994d1403e4d877f6a) Part-of: --- os/connection.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os/connection.c b/os/connection.c index 3fd0b009e..544d05723 100644 --- a/os/connection.c +++ b/os/connection.c @@ -242,7 +242,7 @@ void CreateWellKnownSockets(void) { int i; - int partial; + int partial = 0; /* display is initialized to "0" by main(). It is then set to the display * number if specified on the command line. */