From 5529b07316b75913188c44698aed6c0f866c5da9 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Wed, 4 Jan 2023 07:17:54 +0800 Subject: fix(clipboard): show provider warning when not during batch changes #21451 It is strange that Ex commands that explicitly interact with the clipboard show provider warning, but Normal mode commands do not. --- src/nvim/ops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/nvim/ops.c b/src/nvim/ops.c index d2dba41959..ccfd3ab834 100644 --- a/src/nvim/ops.c +++ b/src/nvim/ops.c @@ -6433,7 +6433,7 @@ static yankreg_T *adjust_clipboard_name(int *name, bool quiet, bool writing) } if (!eval_has_provider("clipboard")) { - if (batch_change_count == 1 && !quiet + if (batch_change_count <= 1 && !quiet && (!clipboard_didwarn || (explicit_cb_reg && !redirecting()))) { clipboard_didwarn = true; // Do NOT error (emsg()) here--if it interrupts :redir we get into -- cgit