summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-08-18 22:57:06 +0200
committerBram Moolenaar <Bram@vim.org>2017-08-18 22:57:06 +0200
commit8e539c51c31461fc602071373bdff9edd1aed25f (patch)
treeb98f1e2ae2e88ff5b26b01104ebbea080a590bc1 /src
parentf66a2cda2c425c441fc5e20c8f8893c9630e3aaa (diff)
downloadvim-git-8e539c51c31461fc602071373bdff9edd1aed25f.tar.gz
patch 8.0.0960: job in terminal does not get CTRL-Cv8.0.0960
Problem: Job in terminal does not get CTRL-C, we send a SIGINT instead. Solution: Don't call may_send_sigint() on CTRL-C. Make CTRL-W CTRL-C end the job.
Diffstat (limited to 'src')
-rw-r--r--src/terminal.c8
-rw-r--r--src/version.c2
2 files changed, 7 insertions, 3 deletions
diff --git a/src/terminal.c b/src/terminal.c
index e8e187b89..8d15d3a99 100644
--- a/src/terminal.c
+++ b/src/terminal.c
@@ -1367,9 +1367,6 @@ terminal_loop(void)
if (c == K_IGNORE)
continue;
-#ifdef UNIX
- may_send_sigint(c, curbuf->b_term->tl_job->jv_pid, 0);
-#endif
#ifdef WIN3264
/* On Windows winpty handles CTRL-C, don't send a CTRL_C_EVENT.
* Use CTRL-BREAK to kill the job. */
@@ -1405,6 +1402,11 @@ terminal_loop(void)
/* Send both keys to the terminal. */
send_keys_to_term(curbuf->b_term, prev_c, TRUE);
}
+ else if (c == Ctrl_C)
+ {
+ /* "CTRL-W CTRL-C" or 'termkey' CTRL-C: end the job */
+ mch_signal_job(curbuf->b_term->tl_job, (char_u *)"kill");
+ }
else if (termkey == 0 && c == '.')
{
/* "CTRL-W .": send CTRL-W to the job */
diff --git a/src/version.c b/src/version.c
index 7b17219fe..a424c6aef 100644
--- a/src/version.c
+++ b/src/version.c
@@ -770,6 +770,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 960,
+/**/
959,
/**/
958,