diff options
Diffstat (limited to 'meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-5574-3.patch')
-rw-r--r-- | meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-5574-3.patch | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-5574-3.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-5574-3.patch deleted file mode 100644 index 47c247ef0c..0000000000 --- a/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2023-5574-3.patch +++ /dev/null | |||
@@ -1,54 +0,0 @@ | |||
1 | From ab2c58ba4719fc31c19c7829b06bdba8a88bd586 Mon Sep 17 00:00:00 2001 | ||
2 | From: Peter Hutterer <peter.hutterer@who-t.net> | ||
3 | Date: Tue, 24 Oct 2023 12:09:36 +1000 | ||
4 | Subject: [PATCH] dix: always initialize pScreen->CloseScreen | ||
5 | |||
6 | CloseScreen is wrapped by the various modules, many of which do not | ||
7 | check if they're the last ones unwrapping. This is fine if the order of | ||
8 | those modules never changes but when it does we might get a NULL-pointer | ||
9 | dereference by some naive code doing a | ||
10 | |||
11 | pScreen->CloseScreen = priv->CloseScreen; | ||
12 | free(priv); | ||
13 | return (*pScreen->CloseScreen)(pScreen); | ||
14 | |||
15 | To avoid this set it to a default function that just returns TRUE that's | ||
16 | guaranteed to be the last one. | ||
17 | |||
18 | Upstream-Status: Backport [https://gitlab.freedesktop.org/xorg/xserver/-/commit/ab2c58ba4719fc31c19c7829b06bdba8a88bd586] | ||
19 | CVE: CVE-2023-5574 | ||
20 | Signed-off-by: Vijay Anusuri <vanusuri@mvista.com> | ||
21 | --- | ||
22 | dix/dispatch.c | 9 +++++++++ | ||
23 | 1 file changed, 9 insertions(+) | ||
24 | |||
25 | diff --git a/dix/dispatch.c b/dix/dispatch.c | ||
26 | index eaac39b7c9..cd092fd409 100644 | ||
27 | --- a/dix/dispatch.c | ||
28 | +++ b/dix/dispatch.c | ||
29 | @@ -3890,6 +3890,12 @@ static int indexForScanlinePad[65] = { | ||
30 | 3 /* 64 bits per scanline pad unit */ | ||
31 | }; | ||
32 | |||
33 | +static Bool | ||
34 | +DefaultCloseScreen(ScreenPtr screen) | ||
35 | +{ | ||
36 | + return TRUE; | ||
37 | +} | ||
38 | + | ||
39 | /* | ||
40 | grow the array of screenRecs if necessary. | ||
41 | call the device-supplied initialization procedure | ||
42 | @@ -3949,6 +3955,9 @@ static int init_screen(ScreenPtr pScreen, int i, Bool gpu) | ||
43 | PixmapWidthPaddingInfo[depth].notPower2 = 0; | ||
44 | } | ||
45 | } | ||
46 | + | ||
47 | + pScreen->CloseScreen = DefaultCloseScreen; | ||
48 | + | ||
49 | return 0; | ||
50 | } | ||
51 | |||
52 | -- | ||
53 | GitLab | ||
54 | |||