From 787673b743a9c976918b705745307a461d8eaa44 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 7 Jul 2020 17:08:51 +0200 Subject: [PATCH] WindowServer: Turn an assertion that happens sometimes into a dbg() It's very annoying to crash the WindowServer when something harmless is a little weird. --- Services/WindowServer/WindowManager.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Services/WindowServer/WindowManager.cpp b/Services/WindowServer/WindowManager.cpp index c56cdfb467..a1e98571dd 100644 --- a/Services/WindowServer/WindowManager.cpp +++ b/Services/WindowServer/WindowManager.cpp @@ -395,7 +395,10 @@ void WindowManager::start_window_resize(Window& window, const Gfx::IntPoint& pos { ResizeDirection::DownLeft, ResizeDirection::Down, ResizeDirection::DownRight }, }; Gfx::IntRect outer_rect = window.frame().rect(); - ASSERT(outer_rect.contains(position)); + if (!outer_rect.contains(position)) { + // FIXME: This used to be an ASSERT but crashing WindowServer over this seems silly. + dbg() << "FIXME: !outer_rect.contains(position): outer_rect=" << outer_rect << ", position=" << position; + } int window_relative_x = position.x() - outer_rect.x(); int window_relative_y = position.y() - outer_rect.y(); int hot_area_row = min(2, window_relative_y / (outer_rect.height() / 3));