aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbfredl <bjorn.linse@gmail.com>2024-03-09 11:52:42 +0100
committerGitHub <noreply@github.com>2024-03-09 11:52:42 +0100
commit9eda2f249574ccbe844a718b7e09fb08854a5481 (patch)
tree205449ce50eb8ce41a3207dd0505c7f2c594d3fa
parent649dd00fe2e54183cc210f24d36504a61e5ea605 (diff)
parentb21d960119344b19f8cec64f8e9d56bfa9cdce85 (diff)
downloadrneovim-9eda2f249574ccbe844a718b7e09fb08854a5481.tar.gz
rneovim-9eda2f249574ccbe844a718b7e09fb08854a5481.tar.bz2
rneovim-9eda2f249574ccbe844a718b7e09fb08854a5481.zip
Merge pull request #27764 from glepnir/grid_null
fix: set full_screen when in ex_mode
-rw-r--r--src/nvim/main.c2
-rw-r--r--test/functional/core/main_spec.lua12
2 files changed, 13 insertions, 1 deletions
diff --git a/src/nvim/main.c b/src/nvim/main.c
index 6b8c8253dc..ea189aaa0c 100644
--- a/src/nvim/main.c
+++ b/src/nvim/main.c
@@ -363,7 +363,7 @@ int main(int argc, char **argv)
setbuf(stdout, NULL); // NOLINT(bugprone-unsafe-functions)
- full_screen = !silent_mode;
+ full_screen = !silent_mode || exmode_active;
// Set the default values for the options that use Rows and Columns.
win_init_size();
diff --git a/test/functional/core/main_spec.lua b/test/functional/core/main_spec.lua
index 1d2261ee05..9d8d64c82d 100644
--- a/test/functional/core/main_spec.lua
+++ b/test/functional/core/main_spec.lua
@@ -73,6 +73,18 @@ describe('command-line option', function()
eq(#'100500\n', attrs.size)
end)
+ it('does not crash when run completion in ex mode', function()
+ fn.system({
+ nvim_prog_abs(),
+ '--clean',
+ '-e',
+ '-s',
+ '--cmd',
+ 'exe "norm! i\\<C-X>\\<C-V>"',
+ })
+ eq(0, eval('v:shell_error'))
+ end)
+
it('does not crash after reading from stdin in non-headless mode', function()
skip(is_os('win'))
local screen = Screen.new(40, 8)