Commit: 3056add0e0b087f7e08781095fcdd99d08ca8f25
Author: Campbell Barton
Date:   Mon Sep 14 23:37:33 2015 +1000
Branches: master
https://developer.blender.org/rB3056add0e0b087f7e08781095fcdd99d08ca8f25

Fix T45699: BGE auto-run exits immediately

===================================================================

M       source/blender/windowmanager/intern/wm_window.c

===================================================================

diff --git a/source/blender/windowmanager/intern/wm_window.c 
b/source/blender/windowmanager/intern/wm_window.c
index 8b7780b..a03f2c2 100644
--- a/source/blender/windowmanager/intern/wm_window.c
+++ b/source/blender/windowmanager/intern/wm_window.c
@@ -1020,6 +1020,10 @@ static int ghost_event_proc(GHOST_EventHandle evt, 
GHOST_TUserDataPtr C_void_ptr
                                                wm_event_do_handlers(C);
                                                wm_event_do_notifiers(C);
                                                wm_draw_update(C);
+
+                                               /* Warning! code above nulls 
'C->wm.window', causing BGE to quit, see: T45699.
+                                                * Further, its easier to match 
behavior across platforms, so restore the window. */
+                                               CTX_wm_window_set(C, win);
 #endif
                                        }
                                }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to