1
0
forked from aniani/vim

patch 8.0.1747: MS-Windows: term_start() does not set job_info() cmd

Problem:    MS-Windows: term_start() does not set job_info() cmd.
Solution:   Share the code from job_start() to set jv_argv.
This commit is contained in:
Bram Moolenaar
2018-04-21 23:34:43 +02:00
parent a69b39511d
commit ebe74b7367
6 changed files with 88 additions and 32 deletions

View File

@@ -5342,6 +5342,18 @@ term_and_job_init(
job = job_alloc();
if (job == NULL)
goto failed;
if (argvar->v_type == VAR_STRING)
{
int argc;
build_argv_from_string(cmd, &job->jv_argv, &argc);
}
else
{
int argc;
build_argv_from_list(argvar->vval.v_list, &job->jv_argv, &argc);
}
if (opt->jo_set & JO_IN_BUF)
job->jv_in_buf = buflist_findnr(opt->jo_io_buf[PART_IN]);