summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0572
diff options
context:
space:
mode:
Diffstat (limited to 'data/vim/patches/8.1.0572')
-rw-r--r--data/vim/patches/8.1.057279
1 files changed, 79 insertions, 0 deletions
diff --git a/data/vim/patches/8.1.0572 b/data/vim/patches/8.1.0572
new file mode 100644
index 000000000..0ae3eefe6
--- /dev/null
+++ b/data/vim/patches/8.1.0572
@@ -0,0 +1,79 @@
+To: vim_dev@googlegroups.com
+Subject: Patch 8.1.0572
+Fcc: outbox
+From: Bram Moolenaar <Bram@moolenaar.net>
+Mime-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+------------
+
+Patch 8.1.0572
+Problem: Stopping a job does not work properly on OpenBSD.
+Solution: Do not use getpgid() to check the process group of the job
+ processs ID, always pass the negative process ID to kill().
+ (George Koehler, closes #3656)
+Files: src/os_unix.c
+
+
+*** ../vim-8.1.0571/src/os_unix.c 2018-11-12 21:45:04.596729428 +0100
+--- src/os_unix.c 2018-12-08 14:37:24.207684926 +0100
+***************
+*** 5820,5826 ****
+ mch_signal_job(job_T *job, char_u *how)
+ {
+ int sig = -1;
+- pid_t job_pid;
+
+ if (*how == NUL || STRCMP(how, "term") == 0)
+ sig = SIGTERM;
+--- 5820,5825 ----
+***************
+*** 5841,5856 ****
+ else
+ return FAIL;
+
+! /* TODO: have an option to only kill the process, not the group? */
+! job_pid = job->jv_pid;
+! #ifdef HAVE_GETPGID
+! if (job_pid == getpgid(job_pid))
+! job_pid = -job_pid;
+! #endif
+!
+! /* Never kill ourselves! */
+! if (job_pid != 0)
+! kill(job_pid, sig);
+
+ return OK;
+ }
+--- 5840,5852 ----
+ else
+ return FAIL;
+
+! // Never kill ourselves!
+! if (job->jv_pid != 0)
+! {
+! // TODO: have an option to only kill the process, not the group?
+! kill(-job->jv_pid, sig);
+! kill(job->jv_pid, sig);
+! }
+
+ return OK;
+ }
+*** ../vim-8.1.0571/src/version.c 2018-12-08 13:57:38.553692769 +0100
+--- src/version.c 2018-12-08 14:38:11.875404358 +0100
+***************
+*** 794,795 ****
+--- 794,797 ----
+ { /* Add new patch number below this line */
++ /**/
++ 572,
+ /**/
+
+--
+FIRST VILLAGER: We have found a witch. May we burn her?
+ "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
+
+ /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
+/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
+\\\ an exciting new programming language -- http://www.Zimbu.org ///
+ \\\ help me help AIDS victims -- http://ICCF-Holland.org ///