diff --git a/glfw/wl_client_side_decorations.c b/glfw/wl_client_side_decorations.c index 9527d648a..53a8160e5 100644 --- a/glfw/wl_client_side_decorations.c +++ b/glfw/wl_client_side_decorations.c @@ -202,9 +202,8 @@ render_title_bar(_GLFWwindow *window, bool to_front_buffer) { if (window->wl.title && window->wl.title[0] && _glfw.callbacks.draw_text) { if (_glfw.callbacks.draw_text((GLFWwindow*)window, window->wl.title, fg_color, bg_color, output, decs.top.buffer.width, decs.top.buffer.height - margin, 0, 0, 0)) return; } - for (uint32_t *px = (uint32_t*)output, *end = (uint32_t*)(output + decs.top.buffer.size_in_bytes); px < end; px++) { - *px = bg_color; - } + // rendering of text failed, blank the buffer + for (uint32_t *px = (uint32_t*)output, *end = (uint32_t*)(output + decs.top.buffer.size_in_bytes); px < end; px++) *px = bg_color; } static void