summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-oe/recipes-graphics/x11vnc/files/src-cursor-fix-xfc-NULL-pointer-dereference.patch30
-rw-r--r--meta-oe/recipes-graphics/x11vnc/x11vnc_0.9.16.bb1
2 files changed, 31 insertions, 0 deletions
diff --git a/meta-oe/recipes-graphics/x11vnc/files/src-cursor-fix-xfc-NULL-pointer-dereference.patch b/meta-oe/recipes-graphics/x11vnc/files/src-cursor-fix-xfc-NULL-pointer-dereference.patch
new file mode 100644
index 0000000000..a571ba2838
--- /dev/null
+++ b/meta-oe/recipes-graphics/x11vnc/files/src-cursor-fix-xfc-NULL-pointer-dereference.patch
@@ -0,0 +1,30 @@
1From 95a10ab64c2dbbec2c8dad91a5ffb73a0d68474b Mon Sep 17 00:00:00 2001
2From: Jonathan Liu <net147@gmail.com>
3Date: Mon, 16 Mar 2020 20:04:06 +1100
4Subject: [PATCH] src/cursor: fix xfc NULL pointer dereference
5
6xfc->width and xfc->height for the XFixes cursor image returned from
7XFixesGetCursorImage(dpy) are accessed without first checking that xfc
8is not NULL. This can result in the server sometimes crashing when
9moving a Google Chrome window.
10
11Fixes: 37c946191a0f ("Broken cursor bugfix for 64 bit systems (#49)")
12Upstream-Status: Accepted
13Signed-off-by: Jonathan Liu <net147@gmail.com>
14---
15 src/cursor.c | 2 +-
16 1 file changed, 1 insertion(+), 1 deletion(-)
17
18diff --git a/src/cursor.c b/src/cursor.c
19index 39e73a6..74a08c6 100644
20--- a/src/cursor.c
21+++ b/src/cursor.c
22@@ -1311,7 +1311,7 @@ static int get_exact_cursor(int init) {
23
24 /* retrieve the cursor info + pixels from server: */
25 xfc = XFixesGetCursorImage(dpy);
26- {
27+ if (xfc) {
28 /* 2017-07-09, Stephan Fuhrmann: This fixes an implementation flaw for 64 bit systems.
29 * The XFixesCursorImage structure says xfc->pixels is (unsigned long*) in the structure, but
30 * the protocol spec says it's 32 bit per pixel
diff --git a/meta-oe/recipes-graphics/x11vnc/x11vnc_0.9.16.bb b/meta-oe/recipes-graphics/x11vnc/x11vnc_0.9.16.bb
index 0d84c420a1..e3a1914fef 100644
--- a/meta-oe/recipes-graphics/x11vnc/x11vnc_0.9.16.bb
+++ b/meta-oe/recipes-graphics/x11vnc/x11vnc_0.9.16.bb
@@ -12,6 +12,7 @@ SRC_URI = "git://github.com/LibVNC/x11vnc \
12 file://starting-fix.patch \ 12 file://starting-fix.patch \
13 file://0001-misc-Makefile.am-don-t-install-Xdummy-when-configure.patch \ 13 file://0001-misc-Makefile.am-don-t-install-Xdummy-when-configure.patch \
14 file://0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch \ 14 file://0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch \
15 file://src-cursor-fix-xfc-NULL-pointer-dereference.patch \
15 " 16 "
16S = "${WORKDIR}/git" 17S = "${WORKDIR}/git"
17 18