summaryrefslogtreecommitdiffstats
path: root/src/tag.c
diff options
context:
space:
mode:
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;