comparison src/terminal.c @ 14449:5faab0545f3c v8.1.0238

patch 8.1.0238: 'buftype' is cleared when using ":term ++hidden cat" commit https://github.com/vim/vim/commit/7da1fb5532890d9c15cdb5b9bec158f9f9c105a7 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Aug 4 16:54:11 2018 +0200 patch 8.1.0238: 'buftype' is cleared when using ":term ++hidden cat" Problem: 'buftype' is cleared when using ":term ++hidden cat". (Marcin Szamotulski) Solution: Set the "options initialized" flag earlier. (closes #3278)
author Christian Brabandt <cb@256bit.org>
date Sat, 04 Aug 2018 17:00:05 +0200
parents 83b870d9ac4b
children ecf6c05d8ac3
comparison
equal deleted inserted replaced
14448:fe6e859a75ad 14449:5faab0545f3c
527 if (opt->jo_eof_chars != NULL) 527 if (opt->jo_eof_chars != NULL)
528 term->tl_eof_chars = vim_strsave(opt->jo_eof_chars); 528 term->tl_eof_chars = vim_strsave(opt->jo_eof_chars);
529 529
530 set_string_option_direct((char_u *)"buftype", -1, 530 set_string_option_direct((char_u *)"buftype", -1,
531 (char_u *)"terminal", OPT_FREE|OPT_LOCAL, 0); 531 (char_u *)"terminal", OPT_FREE|OPT_LOCAL, 0);
532 // Avoid that 'buftype' is reset when this buffer is entered.
533 curbuf->b_p_initialized = TRUE;
532 534
533 /* Mark the buffer as not modifiable. It can only be made modifiable after 535 /* Mark the buffer as not modifiable. It can only be made modifiable after
534 * the job finished. */ 536 * the job finished. */
535 curbuf->b_p_ma = FALSE; 537 curbuf->b_p_ma = FALSE;
536 538