summaryrefslogtreecommitdiffstats
path: root/recipes-graphics/wayland/weston/0004-MGS-1668-xwld-System-can-not-boot-up-to-desktop.patch
blob: 95a88e69bb6adf144af09505b94b806bac06b634 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
From 2e5260168b59c96688b10912cff3d95ec1fbb3d8 Mon Sep 17 00:00:00 2001
From: Meng Mingming <mingming.meng@nxp.com>
Date: Mon, 16 Jan 2017 10:25:29 +0800
Subject: [PATCH 4/5] MGS-1668: xwld: System can not boot up to desktop

System can not boot up to desktop if press touch panel continuously during booting up.
The weston view was not initialed completely, so add a protection to the pointer.

Upstream Status: Denied [Could not reproduce]

Date: MAR 08, 2016
Signed-off-by: Yong Gan <yong.gan@nxp.com>
---
 src/compositor.c | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/src/compositor.c b/src/compositor.c
index b6ef7f3..9d9805d 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -1470,12 +1470,14 @@ weston_view_from_global_fixed(struct weston_view *view,
 {
 	float vxf, vyf;
 
-	weston_view_from_global_float(view,
-				      wl_fixed_to_double(x),
-				      wl_fixed_to_double(y),
-				      &vxf, &vyf);
-	*vx = wl_fixed_from_double(vxf);
-	*vy = wl_fixed_from_double(vyf);
+	if(view != NULL) {
+		weston_view_from_global_float(view,
+						wl_fixed_to_double(x),
+						wl_fixed_to_double(y),
+						&vxf, &vyf);
+		*vx = wl_fixed_from_double(vxf);
+		*vy = wl_fixed_from_double(vyf);
+	}
 }
 
 WL_EXPORT void
-- 
2.7.4