From 9fd95c3e21ec73d11d60601e02ad9ddc06923330 Mon Sep 17 00:00:00 2001
From: Connor McLaughlin <stenzek@gmail.com>
Date: Sat, 21 Mar 2020 21:49:20 +1000
Subject: [PATCH] Common/Rectangle: Fix off-by-one error in Intersects()

---
 src/common/rectangle.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/common/rectangle.h b/src/common/rectangle.h
index 4f4e49e5f..6e93b4a67 100644
--- a/src/common/rectangle.h
+++ b/src/common/rectangle.h
@@ -128,7 +128,7 @@ struct Rectangle
   /// Tests for intersection between two rectangles.
   constexpr bool Intersects(const Rectangle& rhs) const
   {
-    return !(left > rhs.right || rhs.left > right || top > rhs.bottom || rhs.top > bottom);
+    return !(left >= rhs.right || rhs.left >= right || top >= rhs.bottom || rhs.top >= bottom);
   }
 
   /// Tests whether the specified point is contained in the rectangle.