From 58cf81914da3fbcc875cbd4954b62a314be31c9a Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Wed, 26 Jun 2019 20:50:08 -0400 Subject: vim-patch:8.0.1013: terminal window behaves different from a buffer with changes Problem: A terminal window with a running job behaves different from a window containing a changed buffer. Solution: Do not set 'bufhidden' to "hide". Fix that a buffer where a terminal used to run is listed as "[Scratch]". https://github.com/vim/vim/commit/e561a7e2fa511d643c9692d26f4cf65378fd1983 --- src/nvim/buffer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/nvim/buffer.c') diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c index 6a2c06b91f..043ae420cd 100644 --- a/src/nvim/buffer.c +++ b/src/nvim/buffer.c @@ -5241,8 +5241,8 @@ char_u *buf_spname(buf_T *buf) // There is no _file_ when 'buftype' is "nofile", b_sfname // contains the name as specified by the user. if (bt_nofile(buf)) { - if (buf->b_sfname != NULL) { - return buf->b_sfname; + if (buf->b_fname != NULL) { + return buf->b_fname; } return (char_u *)_("[Scratch]"); } -- cgit