From 8cda1b6f677ca93974676f40f610881c993f368f Mon Sep 17 00:00:00 2001 From: Christoph Haag Date: Tue, 13 Aug 2019 01:44:56 +0200 Subject: [PATCH] comp: fix cleanup of direct window, delete with correct type Found by gcc address sanitizer. --- src/xrt/compositor/main/comp_window_direct_mode.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xrt/compositor/main/comp_window_direct_mode.cpp b/src/xrt/compositor/main/comp_window_direct_mode.cpp index 351b1ba88..07e8a46a5 100644 --- a/src/xrt/compositor/main/comp_window_direct_mode.cpp +++ b/src/xrt/compositor/main/comp_window_direct_mode.cpp @@ -197,7 +197,7 @@ comp_window_direct_destroy(struct comp_window* w) w_direct->connection = nullptr; } - delete w; + delete reinterpret_cast(w); } static void