summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrcaridade145 <[email protected]>2020-02-24 10:42:20 +0000
committerraveit65 <[email protected]>2020-03-08 22:33:28 +0100
commit1748fcb3c74836c8f59453f8a1689bb7c612f035 (patch)
tree60a2ee41e7ce040598d2e21ff21bf5c0e330139c /src
parentc0a61756c01f5d8fa1e58fe97d0cb3a9d42c9871 (diff)
downloadmarco-1748fcb3c74836c8f59453f8a1689bb7c612f035.tar.bz2
marco-1748fcb3c74836c8f59453f8a1689bb7c612f035.tar.xz
Guard against null changes introduced by previous commit
Diffstat (limited to 'src')
-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,