summaryrefslogtreecommitdiffstats
path: root/src/tag.c
diff options
context:
space:
mode:
authorColin Kennedy <colinvfx@gmail.com>2024-03-03 16:16:47 +0100
committerChristian Brabandt <cb@256bit.org>2024-03-03 16:16:47 +0100
commit215703563757a4464907ead6fb9edaeb7f430bea (patch)
tree380d7492e2fc174d13a073c6fd4e8dae6714030f /src/tag.c
parent353faa373eb132987a1985cf3abe18c006f8cdf0 (diff)
patch 9.1.0147: Cannot keep a buffer focused in a windowv9.1.0147
Problem: Cannot keep a buffer focused in a window (Amit Levy) Solution: Add the 'winfixbuf' window-local option (Colin Kennedy) fixes: #6445 closes: #13903 Signed-off-by: Colin Kennedy <colinvfx@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'src/tag.c')
-rw-r--r--src/tag.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tag.c b/src/tag.c
index 3df767d192..2ac0da2666 100644
--- a/src/tag.c
+++ b/src/tag.c
@@ -289,6 +289,9 @@ do_tag(
static char_u **matches = NULL;
static int flags;
+ if (postponed_split == 0 && !check_can_set_curbuf_forceit(forceit))
+ return FALSE;
+
#ifdef FEAT_EVAL
if (tfu_in_use)
{
@@ -3705,6 +3708,9 @@ jumpto_tag(
size_t len;
char_u *lbuf;
+ if (postponed_split == 0 && !check_can_set_curbuf_forceit(forceit))
+ return FAIL;
+
// Make a copy of the line, it can become invalid when an autocommand calls
// back here recursively.
len = matching_line_len(lbuf_arg) + 1;