diff options
author | rcaridade145 <[email protected]> | 2020-02-24 10:42:20 +0000 |
---|---|---|
committer | raveit65 <[email protected]> | 2020-03-08 22:44:50 +0100 |
commit | 821f582e74ef0d94fbacce3caa18a40d69e8dfba (patch) | |
tree | 365406fa32191deea3c1750d62d74be9469ca286 /src/compositor/compositor-xrender.c | |
parent | 280e5dba5e26f7c8cc4feba376ed398728dbef8c (diff) | |
download | marco-821f582e74ef0d94fbacce3caa18a40d69e8dfba.tar.bz2 marco-821f582e74ef0d94fbacce3caa18a40d69e8dfba.tar.xz |
Guard against null changes introduced by previous commit
Diffstat (limited to 'src/compositor/compositor-xrender.c')
-rw-r--r-- | src/compositor/compositor-xrender.c | 8 |
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, |