diff src/os_unix.c @ 18514:39b0c28fe495 v8.1.2251

patch 8.1.2251: ":term command" may not work without a shell Commit: https://github.com/vim/vim/commit/197c6b7da3ad4c3e3942a553f5dbc35722a4a349 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Nov 3 23:37:12 2019 +0100 patch 8.1.2251: ":term command" may not work without a shell Problem: ":term command" may not work without a shell. Solution: Add the ++shell option to :term. (closes https://github.com/vim/vim/issues/3340)
author Bram Moolenaar <Bram@vim.org>
date Sun, 03 Nov 2019 23:45:03 +0100
parents 9e6d5a4abb1c
children e3785af3ba0f
line wrap: on
line diff
--- a/src/os_unix.c
+++ b/src/os_unix.c
@@ -4299,10 +4299,10 @@ may_send_sigint(int c UNUSED, pid_t pid 
 # endif
 }
 
-#if !defined(USE_SYSTEM) || (defined(FEAT_GUI) && defined(FEAT_TERMINAL))
-
-    static int
-build_argv(
+#if !defined(USE_SYSTEM) || defined(FEAT_TERMINAL) || defined(PROTO)
+
+    int
+unix_build_argv(
 	char_u *cmd,
 	char ***argvp,
 	char_u **sh_tofree,
@@ -4369,7 +4369,7 @@ mch_call_shell_terminal(
     aco_save_T	aco;
     oparg_T	oa;		/* operator arguments */
 
-    if (build_argv(cmd, &argv, &tofree1, &tofree2) == FAIL)
+    if (unix_build_argv(cmd, &argv, &tofree1, &tofree2) == FAIL)
 	goto theend;
 
     init_job_options(&opt);
@@ -4546,7 +4546,7 @@ mch_call_shell_fork(
     if (options & SHELL_COOKED)
 	settmode(TMODE_COOK);		/* set to normal mode */
 
-    if (build_argv(cmd, &argv, &tofree1, &tofree2) == FAIL)
+    if (unix_build_argv(cmd, &argv, &tofree1, &tofree2) == FAIL)
 	goto error;
 
     /*