diff src/terminal.c @ 13474:8a8daeb057d1 v8.0.1611

patch 8.0.1611: CTRL-W in system terminal does not go to job commit https://github.com/vim/vim/commit/af23bad0fd05b1f6495287089387a1f97efa5b49 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Mar 16 22:20:49 2018 +0100 patch 8.0.1611: CTRL-W in system terminal does not go to job Problem: CTRL-W in system terminal does not go to job. Solution: Do not use CTRL-W as a terminal command in a system terminal.
author Christian Brabandt <cb@256bit.org>
date Fri, 16 Mar 2018 22:30:07 +0100
parents f6a4614edea4
children d130044d4f1f
line wrap: on
line diff
--- a/src/terminal.c
+++ b/src/terminal.c
@@ -2007,8 +2007,13 @@ terminal_loop(int blocking)
 	if (ctrl_break_was_pressed)
 	    mch_signal_job(curbuf->b_term->tl_job, (char_u *)"kill");
 #endif
-	/* Was either CTRL-W (termkey) or CTRL-\ pressed? */
-	if (c == (termkey == 0 ? Ctrl_W : termkey) || c == Ctrl_BSL)
+	/* Was either CTRL-W (termkey) or CTRL-\ pressed?
+	 * Not in a system terminal. */
+	if ((c == (termkey == 0 ? Ctrl_W : termkey) || c == Ctrl_BSL)
+#ifdef FEAT_GUI
+		&& !curbuf->b_term->tl_system
+#endif
+		)
 	{
 	    int	    prev_c = c;