From 8f58c060fd6095e34ede2a2d1c14caea517636e7 Mon Sep 17 00:00:00 2001 From: Kirill Primak Date: Sun, 27 Nov 2022 13:34:48 +0300 Subject: util/region: forbid "shrinking" a region with wlr_region_expand() The logic isn't correct. --- include/wlr/util/region.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/wlr') diff --git a/include/wlr/util/region.h b/include/wlr/util/region.h index c3f1cbe8..948307a1 100644 --- a/include/wlr/util/region.h +++ b/include/wlr/util/region.h @@ -39,8 +39,8 @@ void wlr_region_transform(pixman_region32_t *dst, const pixman_region32_t *src, enum wl_output_transform transform, int width, int height); /** - * Expands the region of `distance`. If `distance` is negative, it shrinks the - * region. + * Expands the region by distance on both axis. distance must be + * a non-negative number. */ void wlr_region_expand(pixman_region32_t *dst, const pixman_region32_t *src, int distance); -- cgit v1.2.3