forked from aniani/vim
patch 8.0.0836: can abandon a terminal buffer after making a change
Problem: When a terminal buffer is changed it can still be accidentally abandoned. Solution: When making a change reset the 'buftype' option.
This commit is contained in:
@@ -8228,7 +8228,8 @@ set_bool_option(
|
||||
{
|
||||
# ifdef FEAT_TERMINAL
|
||||
/* Cannot set 'modifiable' when in Terminal mode. */
|
||||
if (term_in_terminal_mode())
|
||||
if (term_in_terminal_mode()
|
||||
|| (bt_terminal(curbuf) && !term_is_finished(curbuf)))
|
||||
{
|
||||
curbuf->b_p_ma = FALSE;
|
||||
return (char_u *)N_("E946: Cannot make a terminal with running job modifiable");
|
||||
|
Reference in New Issue
Block a user