zeertzjq
42cd192daa
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 : #14817
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-05-21 17:19:58 +02:00
John Marriott
8c85a2a49a
patch 9.1.0426: too many strlen() calls in search.c
...
Problem: too many strlen() calls in search.c
Solution: refactor code and remove more strlen() calls,
use explicit variable to remember strlen
(John Marriott)
closes : #14796
Signed-off-by: John Marriott <basilisk@internode.on.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-05-20 19:18:26 +02:00
zeertzjq
620e85265c
patch 9.1.0216: Error on exit with EXITFREE and 'winfixbuf'
...
Problem: Error on exit with EXITFREE and 'winfixbuf'.
Solution: Handle DT_FREE before checking for 'winfixbuf'.
(zeertzjq)
closes : #14314
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-03-28 10:11:57 +01:00
Colin Kennedy
2157035637
patch 9.1.0147: Cannot keep a buffer focused in a window
...
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>
2024-03-03 16:16:47 +01:00
zeertzjq
c86bff1771
patch 9.1.0115: Using freed memory with full tag stack and user data
...
Problem: Using freed memory with full tag stack and user data
(Konstantin Khlebnikov)
Solution: Clear the user data pointer of the newest entry.
(zeertzjq, Konstantin Khlebnikov)
fixes: neovim/neovim#27498
closes : #14053
Co-authored-by: Konstantin Khlebnikov koct9i@gmail.com
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Konstantin Khlebnikov koct9i@gmail.com
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-02-18 18:57:07 +01:00
Keith Thompson
184f71cc68
patch 9.1.0006: is*() and to*() function may be unsafe
...
Problem: is*() and to*() function may be unsafe
Solution: Add SAFE_* macros and start using those instead
(Keith Thompson)
Use SAFE_() macros for is*() and to*() functions
The standard is*() and to*() functions declared in <ctype.h> have
undefined behavior for negative arguments other than EOF. If plain char
is signed, passing an unchecked value from argv for from user input
to one of these functions has undefined behavior.
Solution: Add SAFE_*() macros that cast the argument to unsigned char.
Most implementations behave sanely for negative arguments, and most
character values in practice are non-negative, but it's still best
to avoid undefined behavior.
The change from #13347 has been omitted, as this has already been
separately fixed in commit ac709e2fc0db6d31abb7da96f743c40956b60c3a
(v9.0.2054)
fixes : #13332
closes : #13347
Signed-off-by: Keith Thompson <Keith.S.Thompson@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-01-04 21:19:04 +01:00
Bram Moolenaar
79cdf026f1
patch 9.0.1571: RedrawingDisabled not used consistently
...
Problem: RedrawingDisabled not used consistently.
Solution: Avoid RedrawingDisabled going negative. Set RedrawingDisabled in
win_split_ins(). (closes #11961 )
2023-05-20 14:07:00 +01:00
Yegappan Lakshmanan
e42c27d9e8
patch 9.0.1554: code for handling 'switchbuf' is repeated
...
Problem: Code for handling 'switchbuf' is repeated.
Solution: Add a function to handle 'switchbuf'. (Yegappan Lakshmanan,
closes #12397 )
2023-05-14 17:24:22 +01:00
Yegappan Lakshmanan
af93691b53
patch 9.0.1330: handling new value of an option has a long "else if" chain
...
Problem: Handling new value of an option has a long "else if" chain.
Solution: Use a function pointer. (Yegappan Lakshmanan, closes #12015 )
2023-02-20 12:16:39 +00:00
Yegappan Lakshmanan
f2e30d0c44
patch 9.0.1262: the did_set_string_option function is too long
...
Problem: The did_set_string_option function is too long.
Solution: Split off functionality to individual functions. (Yegappan
Lakshmanan, Lewis Russell, closes #11904 )
2023-01-30 13:04:42 +00:00
Yegappan Lakshmanan
fadc02a2a5
patch 9.0.1251: checking returned value of ga_grow() is inconsistent
...
Problem: Checking returned value of ga_grow() is inconsistent.
Solution: Check for FAIL instaed of "not OK". (Yegappan Lakshmanan,
closes #11897 )
2023-01-27 21:03:12 +00:00
Yegappan Lakshmanan
032713f829
patch 9.0.1245: code is indented more than necessary
...
Problem: Code is indented more than necessary.
Solution: Use an early return where it makes sense. (Yegappan Lakshmanan,
closes #11879 )
2023-01-25 21:05:38 +00:00
zeertzjq
df3c0eb41e
patch 9.0.0925: two conditions are always false
...
Problem: Two conditions are always false.
Solution: Remove the conditions. Update return value types to make clear
what could be returned. (closes #11593 )
2022-11-23 11:23:17 +00:00
dundargoc
c57b5bcd22
patch 9.0.0828: various typos
...
Problem: Various typos.
Solution: Correct typos. (closes #11432 )
2022-11-02 13:30:51 +00:00
Bram Moolenaar
ccfde4d028
patch 9.0.0389: crash when 'tagfunc' closes the window
...
Problem: Crash when 'tagfunc' closes the window.
Solution: Bail out when the window was closed.
2022-09-05 19:51:13 +01:00
Bram Moolenaar
89083466fa
patch 9.0.0368: old Coverity warning for using NULL pointer
...
Problem: Old Coverity warning for using NULL pointer.
Solution: Bail out if dictionary allocation fails.
2022-09-03 12:59:19 +01:00
Yegappan Lakshmanan
c99e182e1f
patch 9.0.0364: clang static analyzer gives warnings
...
Problem: Clang static analyzer gives warnings.
Solution: Avoid the warnings. (Yegappan Lakshmanan, closes #11043 )
2022-09-03 10:52:24 +01:00
Bram Moolenaar
2bd9dbc19f
patch 9.0.0270: some values of 'path' and 'tags' invalid in the tiny version
...
Problem: Some values of 'path' and 'tags' do not work in the tiny version.
Solution: Graduate the +path_extra feature.
2022-08-25 18:12:06 +01:00
Bram Moolenaar
adce965162
patch 9.0.0246: using freed memory when 'tagfunc' deletes the buffer
...
Problem: Using freed memory when 'tagfunc' deletes the buffer.
Solution: Make a copy of the tag name.
2022-08-22 16:35:45 +01:00
Bram Moolenaar
a4d158b3c8
patch 9.0.0206: redraw flags are not named specifically
...
Problem: Redraw flags are not named specifically.
Solution: Prefix "UPD_" to the flags, for UPDate_screen().
2022-08-14 14:17:45 +01:00
Bram Moolenaar
d61efa50f8
patch 9.0.0063: too many type casts for dict_get functions
...
Problem: Too many type casts for dict_get functions.
Solution: Change the key argument from "char_u *" to "char *".
2022-07-23 09:52:04 +01:00
Bram Moolenaar
6ed545e797
patch 8.2.4928: various white space and cosmetic mistakes
...
Problem: Various white space and cosmetic mistakes.
Solution: Change spaces to tabs, improve comments.
2022-05-09 20:09:23 +01:00
Bram Moolenaar
249591057b
patch 8.2.4911: the mode #defines are not clearly named
...
Problem: The mode #defines are not clearly named.
Solution: Prepend MODE_. Renumber them to put the mapped modes first.
2022-05-07 20:01:16 +01:00
Yegappan Lakshmanan
4829c1c9e9
patch 8.2.4683: verbose check with dict_find() to see if a key is present
...
Problem: Verbose check with dict_find() to see if a key is present.
Solution: Add dict_has_key(). (Yegappan Lakshmanan, closes #10074 )
2022-04-04 15:16:54 +01:00
Yegappan Lakshmanan
b29b96806f
patch 8.2.4562: linear tag search is not optimal
...
Problem: Linear tag search is not optimal.
Solution: Improve linear tag search performance. (Yegappan Lakshmanan,
closes #9944 )
2022-03-13 19:23:48 +00:00
Yegappan Lakshmanan
8b530b3158
patch 8.2.4553: linear tag search is a bit slow
...
Problem: Linear tag search is a bit slow.
Solution: Remove a vim_ftell() call. (Yegappan Lakshmanan, closes #9937 )
2022-03-12 17:38:29 +00:00
Bram Moolenaar
dbf8094b17
patch 8.2.4544: Coverity warnings for not using returned value
...
Problem: Coverity warnings for not using returned value.
Solution: Assign to vim_ignored.
2022-03-11 14:54:03 +00:00
Yegappan Lakshmanan
20fb28b1dc
patch 8.2.4543: Coverity warning for refactored tag search code
...
Problem: Coverity warning for refactored tag search code.
Solution: Avoid the warnings. Update comments. Add one more test case.
(Yegappan Lakshmanan, closes #9928 )
2022-03-11 12:05:18 +00:00
Yegappan Lakshmanan
bf40e90dfe
patch 8.2.4538: the find_tags_in_file() function is too long
...
Problem: The find_tags_in_file() function is too long.
Solution: Refactor into smaller functions. (Yegappan Lakshmanan,
closes #9920 )
2022-03-10 18:36:54 +00:00
Yegappan Lakshmanan
655b734ee8
patch 8.2.4518: the binary tag search feature is always enabled
...
Problem: The binary tag search feature is always enabled.
Solution: Remove the #ifdefs. Add a few more tests. (Yegappan Lakshmanan,
closes #9893 )
2022-03-06 14:27:10 +00:00
Yegappan Lakshmanan
df1bbea436
patch 8.2.4512: the find_tags_in_file() function is much too long
...
Problem: The find_tags_in_file() function is much too long.
Solution: Refactor into multiple smaller functions. (Yegappan Lakshmanan,
closes #9892 )
2022-03-05 14:35:12 +00:00
Bram Moolenaar
fe9112e630
patch 8.2.4496: Coverity gives warnings after tags code refactoring
...
Problem: Coverity gives warnings after tags code refactoring.
Solution: Avoid the warnings. (Yegappan Lakshmanan, closes #9882 )
2022-03-03 10:44:17 +00:00
Yegappan Lakshmanan
2f87a99b6e
patch 8.2.4494: the find_tags() function is much too long
...
Problem: The find_tags() function is much too long.
Solution: Refactor the function. (Yegappan Lakshmanan, closes #9869 )
2022-03-02 20:29:35 +00:00
=?UTF-8?q?Dundar=20G=C3=B6c?=
420fabcd4f
patch 8.2.4241: some type casts are redundant
...
Problem: Some type casts are redundant.
Solution: Remove the type casts. (closes #9643 )
2022-01-28 15:28:04 +00:00
Bram Moolenaar
04935fb17e
patch 8.2.4043: using int for second argument of ga_init2()
...
Problem: Using int for second argument of ga_init2().
Solution: Remove unnessary type cast (int) when using sizeof().
2022-01-08 16:19:22 +00:00
Dominique Pelle
748b308eeb
patch 8.2.4038: various code not used when features are disabled
...
Problem: Various code not used when features are disabled.
Solution: Add #ifdefs. (Dominique Pellé, closes #9491 )
2022-01-08 12:41:16 +00:00
Bram Moolenaar
d82a47dd04
patch 8.2.4012: error messages are spread out
...
Problem: Error messages are spread out.
Solution: Move the last error messages to errors.h.
2022-01-05 20:24:39 +00:00
Bram Moolenaar
1d423ef75f
patch 8.2.3987: error messages are spread out
...
Problem: Error messages are spread out.
Solution: Move more error messages to errors.h.
2022-01-02 21:26:16 +00:00
Bram Moolenaar
ac78dd4a35
patch 8.2.3985: error messages are spread out
...
Problem: Error messages are spread out.
Solution: Move more error messages to errors.h.
2022-01-02 19:25:26 +00:00
Bram Moolenaar
460ae5dfca
patch 8.2.3967: error messages are spread out
...
Problem: Error messages are spread out.
Solution: Move more errors to errors.h.
2022-01-01 14:19:49 +00:00
Yegappan Lakshmanan
6ae8fae869
patch 8.2.3788: lambda for option that is a function may be freed
...
Problem: Lambda for option that is a function may be garbage collected.
Solution: Set a reference in the funcref. (Yegappan Lakshmanan,
closes #9330 )
2021-12-12 16:26:44 +00:00
Bram Moolenaar
f8e9eb8e17
patch 8.2.3776: when a tags file line is long a tag may not be found
...
Problem: When a tags file line is long a tag may not be found.
Solution: When increasing the buffer size read the same line again.
2021-12-10 20:15:15 +00:00
Yegappan Lakshmanan
4dc24eb5ad
patch 8.2.3756: might crash when callback is not valid
...
Problem: might crash when callback is not valid.
Solution: Check for valid callback. (Yegappan Lakshmanan, closes #9293 )
2021-12-07 12:23:57 +00:00
Bram Moolenaar
12f3c1b77f
patch 8.2.3749: error messages are everywhere
...
Problem: Error messages are everywhere.
Solution: Move more error messages to errors.h and adjust the names.
2021-12-05 21:46:34 +00:00
Yegappan Lakshmanan
8658c759f0
patch 8.2.3725: cannot use a lambda for 'completefunc' and 'omnifunc'
...
Problem: Cannot use a lambda for 'completefunc' and 'omnifunc'.
Solution: Implement lambda support. (Yegappan Lakshmanan, closes #9257 )
2021-12-03 11:09:29 +00:00
Yegappan Lakshmanan
19916a8c89
patch 8.2.3665: cannot use a lambda for 'tagfunc'
...
Problem: Cannot use a lambda for 'tagfunc'.
Solution: Use 'tagfunc' like 'opfunc'. (Yegappan Lakshmanan, closes #9204 )
2021-11-24 16:32:55 +00:00
=?UTF-8?q?Dundar=20G=C3=B6c?=
dfa5e464d4
patch 8.2.3460: some type casts are not needed
...
Problem: Some type casts are not needed.
Solution: Remove unnecessary type casts. (closes #8934 )
2021-10-02 11:26:51 +01:00
Gregory Anders
489d60996d
patch 8.2.3362: buffer overflow when completing long tag name
...
Problem: Buffer overflow when completing long tag name.
Solution: Allocate the buffer dynamically. (Gregory Anders, closes #8769 )
2021-08-21 16:21:19 +02:00
Bram Moolenaar
7deb4115ef
patch 8.2.3330: Coverity reports using uninitialized field
...
Problem: Coverity reports using uninitialized field.
Solution: Initialize the field early.
2021-08-11 17:01:45 +02:00
Bram Moolenaar
547f94f330
patch 8.2.3167: get E12 in a job callback when searching for tags
...
Problem: Get E12 in a job callback when searching for tags. (Andy Stewart)
Solution: Use the sandbox only for executing a command, not for searching.
(closes #8511 )
2021-07-15 18:14:56 +02:00