summaryrefslogtreecommitdiff
path: root/src/compositor
diff options
context:
space:
mode:
authorrcaridade145 <[email protected]>2020-02-24 10:42:20 +0000
committerraveit65 <[email protected]>2020-03-09 13:34:30 +0100
commit4ae91ff847a9d4c78dbe9eb882f3bba36f7493ef (patch)
treeaeb38e9a8e572e939f5115ae58e0963621f5fb64 /src/compositor
parentf77dbd234236322d99ae4df6bf07d06db7709d3a (diff)
downloadmarco-4ae91ff847a9d4c78dbe9eb882f3bba36f7493ef.tar.bz2
marco-4ae91ff847a9d4c78dbe9eb882f3bba36f7493ef.tar.xz
Guard against null changes introduced by previous commit
Diffstat (limited to 'src/compositor')
-rw-r--r--src/compositor/compositor-xrender.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/compositor/compositor-xrender.c b/src/compositor/compositor-xrender.c
index dc7ac15f..4a05bc7a 100644
--- a/src/compositor/compositor-xrender.c
+++ b/src/compositor/compositor-xrender.c
@@ -645,7 +645,7 @@ shadow_picture_clip (Display *xdisplay,
visible_region = meta_window_get_frame_bounds (cw->window);
- if (!visible_region)
+ if (visible_region == NULL)
return;
shadow_dx = -1 * (int) shadow_offsets_x [cw->shadow_type] - borders.invisible.left;
@@ -1153,9 +1153,13 @@ border_size (MetaCompWindow *cw)
{
visible_region = meta_window_get_frame_bounds (cw->window);
- if (visible_region)
+ if (visible_region != NULL) {
visible = cairo_region_to_xserver_region (xdisplay, visible_region);
+ }
+ else {
+ g_warning ("Visible region is null");
}
+ }
meta_error_trap_push (display);
border = XFixesCreateRegionFromWindow (xdisplay, cw->id,