patch 8.0.0761: options not set properly for a terminal buffer

Problem:    Options of a buffer for a terminal window are not set properly.
Solution:   Add "terminal" value for 'buftype'.  Make 'buftype' and
            'bufhidden' not depend on the quickfix feature.
            Also set the buffer name and show "running" or "finished" in the
            window title.
diff --git a/src/channel.c b/src/channel.c
index c79107c..9885dfe 100644
--- a/src/channel.c
+++ b/src/channel.c
@@ -4696,6 +4696,10 @@
 	 * not use "job" after this! */
 	job_free(job);
     }
+
+#ifdef FEAT_TERMINAL
+    term_job_ended(job);
+#endif
 }
 
 /*