]> git.eshelyaron.com Git - emacs.git/commitdiff
* src/dispnew.c (rect_intersect): Fix a typo (bug#76592)
authorGerd Möllmann <gerd.moellmann@gmail.com>
Thu, 27 Feb 2025 05:56:02 +0000 (06:56 +0100)
committerEshel Yaron <me@eshelyaron.com>
Fri, 28 Feb 2025 11:18:33 +0000 (12:18 +0100)
(cherry picked from commit 3de9994b9e7acf2a05e6b661a7cd440b7cb0365b)

src/dispnew.c

index f7dbeb22b402618d231e1b0f546aa01fd1ec1c4a..3bbc87f87115a783662c942da232b6177f67ab30 100644 (file)
@@ -3290,7 +3290,7 @@ rect_intersect (struct rect *r, struct rect r1, struct rect r2)
   int w = min (r1.x + r1.w, r2.x + r2.w) - x;
   int h = min (r1.y + r1.h, r2.y + r2.h) - y;
 
-  if (w == 0 || h == 0)
+  if (w <= 0 || h <= 0)
     return false;
 
   *r = (struct rect) { .x = x, .y = y, .w = w, .h = h };