aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-05-22 05:35:21 +0800
committerzeertzjq <zeertzjq@outlook.com>2024-05-22 06:37:26 +0800
commit59fe8ffdeaacc08b811aa97d270daec6d6ed2769 (patch)
tree6a9e75cb83c78c1828ef96fda8d6b1a607a461d3 /src
parentb86381f425223adf0ff91fa0746914a5774ddabb (diff)
downloadrneovim-59fe8ffdeaacc08b811aa97d270daec6d6ed2769.tar.gz
rneovim-59fe8ffdeaacc08b811aa97d270daec6d6ed2769.tar.bz2
rneovim-59fe8ffdeaacc08b811aa97d270daec6d6ed2769.zip
vim-patch:9.1.0428: Tag guessing leaves wrong search history with very short names
Problem: Tag guessing leaves wrong search history with very short names (after 9.1.0426). Solution: Use the correct variable for pattern length (zeertzjq). closes: vim/vim#14817 https://github.com/vim/vim/commit/42cd192daa4b7f29131c7be1beaecb6067e96266 Cherry-pick Test_tagbsearch() changes from patch 9.0.0767.
Diffstat (limited to 'src')
-rw-r--r--src/nvim/tag.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/tag.c b/src/nvim/tag.c
index f322438485..e7f483dd3d 100644
--- a/src/nvim/tag.c
+++ b/src/nvim/tag.c
@@ -2978,7 +2978,7 @@ static int jumpto_tag(const char *lbuf_arg, int forceit, bool keep_help)
// Guess again: "^char * \<func ("
pbuflen = (size_t)snprintf(pbuf, LSIZE, "^\\[#a-zA-Z_]\\.\\*\\<%s\\s\\*(",
tagp.tagname);
- if (!do_search(NULL, '/', '/', pbuf, len, 1, search_options, NULL)) {
+ if (!do_search(NULL, '/', '/', pbuf, pbuflen, 1, search_options, NULL)) {
found = 0;
}
}