aboutsummaryrefslogtreecommitdiff
path: root/sway/tree/container.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/tree/container.c')
-rw-r--r--sway/tree/container.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/tree/container.c b/sway/tree/container.c
index 438ff157..bec17d95 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -1623,6 +1623,10 @@ static void update_marks_texture(struct sway_container *con,
"%s", buffer);
cairo_destroy(c);
+ if (width == 0 || height == 0) {
+ return;
+ }
+
cairo_surface_t *surface = cairo_image_surface_create(
CAIRO_FORMAT_ARGB32, width, height);
cairo_t *cairo = cairo_create(surface);