patch 8.0.0087
Problem: When the channel callback gets job info the job may already have
been deleted. (lifepillar)
Solution: Do not delete the job when the channel is still useful. (ichizok,
closes #1242, closes #1245)
diff --git a/src/eval.c b/src/eval.c
index 7ca129b..9d2c5ac 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -7290,7 +7290,7 @@
if (job == NULL)
return (char_u *)"no process";
status = job->jv_status == JOB_FAILED ? "fail"
- : job->jv_status == JOB_ENDED ? "dead"
+ : job->jv_status >= JOB_ENDED ? "dead"
: "run";
# ifdef UNIX
vim_snprintf((char *)buf, NUMBUFLEN,