[Bf-blender-cvs] [fd95e3275a1] vr_scene_inspection: Fix memory leak when closing Blender while VR session runs
Julian Eisel
noreply at git.blender.org
Fri Dec 13 17:49:25 CET 2019
Commit: fd95e3275a1eacc99c3b78fb7ee0384a4cf5ff2e
Author: Julian Eisel
Date: Fri Dec 13 17:48:54 2019 +0100
Branches: vr_scene_inspection
https://developer.blender.org/rBfd95e3275a1eacc99c3b78fb7ee0384a4cf5ff2e
Fix memory leak when closing Blender while VR session runs
===================================================================
M source/blender/windowmanager/intern/wm.c
===================================================================
diff --git a/source/blender/windowmanager/intern/wm.c b/source/blender/windowmanager/intern/wm.c
index 8cf08bf42bb..2583a246cd2 100644
--- a/source/blender/windowmanager/intern/wm.c
+++ b/source/blender/windowmanager/intern/wm.c
@@ -354,6 +354,11 @@ void wm_close_and_free(bContext *C, wmWindowManager *wm)
wm_autosave_timer_ended(wm);
}
+#ifdef WITH_OPENXR
+ /* May send notifier, so do before freeing notifier queue. */
+ wm_xr_data_destroy(wm);
+#endif
+
while ((win = BLI_pophead(&wm->windows))) {
/* prevent draw clear to use screen */
BKE_workspace_active_set(win->workspace_hook, NULL);
@@ -374,10 +379,6 @@ void wm_close_and_free(bContext *C, wmWindowManager *wm)
WM_msgbus_destroy(wm->message_bus);
}
-#ifdef WITH_OPENXR
- wm_xr_data_destroy(wm);
-#endif
-
BLI_freelistN(&wm->paintcursors);
WM_drag_free_list(&wm->drags);
More information about the Bf-blender-cvs
mailing list