patch 7.4.1496
Problem:    Crash when built with GUI but it's not active. (Dominique Pelle)
Solution:   Check gui.in_use.
diff --git a/src/channel.c b/src/channel.c
index da13f96..6ede916 100644
--- a/src/channel.c
+++ b/src/channel.c
@@ -1046,8 +1046,11 @@
     cursor_on();
     out_flush();
 #ifdef FEAT_GUI
-    gui_update_cursor(TRUE, FALSE);
-    gui_mch_flush();
+    if (gui.in_use)
+    {
+	gui_update_cursor(TRUE, FALSE);
+	gui_mch_flush();
+    }
 #endif
 }