Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/windowmanager/intern/wm_window.c')
-rw-r--r--source/blender/windowmanager/intern/wm_window.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_window.c b/source/blender/windowmanager/intern/wm_window.c
index 89bf2b82426..a4f92da2774 100644
--- a/source/blender/windowmanager/intern/wm_window.c
+++ b/source/blender/windowmanager/intern/wm_window.c
@@ -1546,6 +1546,13 @@ void wm_ghost_init(bContext *C)
g_system = GHOST_CreateSystem();
+ if (UNLIKELY(g_system == NULL)) {
+ /* GHOST will have reported the back-ends that failed to load. */
+ fprintf(stderr, "GHOST: unable to initialize, exiting!\n");
+ /* This will leak memory, it's preferable to crashing. */
+ exit(1);
+ }
+
GHOST_Debug debug = {0};
if (G.debug & G_DEBUG_GHOST) {
debug.flags |= GHOST_kDebugDefault;