diff options
author | Famiu Haque <famiuhaque@proton.me> | 2024-01-10 04:15:22 +0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-10 06:15:22 +0800 |
commit | 10f36af84d4ccb0b626cd6c79c6ba2f2735a56fd (patch) | |
tree | cffc1614f18b97712a9fb332deba53a7b21dc0a4 /src/nvim/ex_docmd.c | |
parent | 501cf323575864c847be892da1197daa8c3771a1 (diff) | |
download | rneovim-10f36af84d4ccb0b626cd6c79c6ba2f2735a56fd.tar.gz rneovim-10f36af84d4ccb0b626cd6c79c6ba2f2735a56fd.tar.bz2 rneovim-10f36af84d4ccb0b626cd6c79c6ba2f2735a56fd.zip |
refactor(options): remove `OPT_FREE` (#26963)
Problem: `OPT_FREE` macro doesn't seem to do anything as `P_ALLOCED`
already handles allocations.
Solution: Remove `OPT_FREE`.
Diffstat (limited to 'src/nvim/ex_docmd.c')
-rw-r--r-- | src/nvim/ex_docmd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/ex_docmd.c b/src/nvim/ex_docmd.c index 0b6efdaab6..49c5f4e610 100644 --- a/src/nvim/ex_docmd.c +++ b/src/nvim/ex_docmd.c @@ -2654,7 +2654,7 @@ static void apply_cmdmod(cmdmod_T *cmod) // Set 'eventignore' to "all". // First save the existing option value for restoring it later. cmod->cmod_save_ei = xstrdup(p_ei); - set_string_option_direct(kOptEventignore, "all", OPT_FREE, SID_NONE); + set_string_option_direct(kOptEventignore, "all", 0, SID_NONE); } } @@ -2674,7 +2674,7 @@ void undo_cmdmod(cmdmod_T *cmod) if (cmod->cmod_save_ei != NULL) { // Restore 'eventignore' to the value before ":noautocmd". - set_string_option_direct(kOptEventignore, cmod->cmod_save_ei, OPT_FREE, SID_NONE); + set_string_option_direct(kOptEventignore, cmod->cmod_save_ei, 0, SID_NONE); free_string_option(cmod->cmod_save_ei); cmod->cmod_save_ei = NULL; } |