# HG changeset patch # User Christian Brabandt # Date 1536516007 -7200 # Node ID e2497d9c51c4e8270b717add776cee93a0da559f # Parent 0dea97ff819ec35d9fddc71d74b743c1f8b64534 patch 8.1.0358: crash when using term_dumpwrite() after the job finished commit https://github.com/vim/vim/commit/a5c48c2698291e59244a705af1b7dbc60e03b09c Author: Bram Moolenaar Date: Sun Sep 9 19:56:07 2018 +0200 patch 8.1.0358: crash when using term_dumpwrite() after the job finished Problem: Crash when using term_dumpwrite() after the job finished. Solution: Check for a finished job and give an error message. diff --git a/src/terminal.c b/src/terminal.c --- a/src/terminal.c +++ b/src/terminal.c @@ -3871,6 +3871,11 @@ f_term_dumpwrite(typval_T *argvars, typv if (buf == NULL) return; term = buf->b_term; + if (term->tl_vterm == NULL) + { + EMSG(_("E958: Job already finished")); + return; + } if (argvars[2].v_type != VAR_UNKNOWN) { diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -795,6 +795,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 358, +/**/ 357, /**/ 356,