projects
/
platform
/
upstream
/
weston.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e55c86a
)
xwayland/window-manager: add a NULL check to fail when frame_create fails
author
Jimmy Ohn
<yongjin.ohn@lge.com>
Wed, 1 Jul 2020 10:11:52 +0000
(19:11 +0900)
committer
Jimmy Ohn
<yongjin.ohn@lge.com>
Wed, 1 Jul 2020 10:16:13 +0000
(19:16 +0900)
This adds a NULL check to fail when frame_create fails. This can happen
crash in frame_resize_inside function if frame is NULL.
xwayland/window-manager.c
patch
|
blob
|
history
diff --git
a/xwayland/window-manager.c
b/xwayland/window-manager.c
index
747bf36
..
de86821
100644
(file)
--- a/
xwayland/window-manager.c
+++ b/
xwayland/window-manager.c
@@
-1082,6
+1082,10
@@
weston_wm_window_create_frame(struct weston_wm_window *window)
window->frame = frame_create(window->wm->theme,
window->width, window->height,
buttons, window->name, NULL);
+
+ if (!window->frame)
+ return;
+
frame_resize_inside(window->frame, window->width, window->height);
weston_wm_window_get_frame_size(window, &width, &height);