aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_meta/api.lua
diff options
context:
space:
mode:
authorGregory Anders <8965202+gpanders@users.noreply.github.com>2023-11-14 17:02:57 -0600
committerGitHub <noreply@github.com>2023-11-14 17:02:57 -0600
commitba58c6f8a44c9c37e97fce1d802dc5b5defceb3d (patch)
treed8692391000b997bad511f5391e4dc727fc3ad9a /runtime/lua/vim/_meta/api.lua
parentc37f7bdba5069eb989c3374c660b540e7539f874 (diff)
downloadrneovim-ba58c6f8a44c9c37e97fce1d802dc5b5defceb3d.tar.gz
rneovim-ba58c6f8a44c9c37e97fce1d802dc5b5defceb3d.tar.bz2
rneovim-ba58c6f8a44c9c37e97fce1d802dc5b5defceb3d.zip
fix: only attempt to close timer if not already closing (#26047)
This fixes an error that can occur in certain pathological cases when the autocommand fires at just the right time such that it attempts to close the timer after the timer has already exited, but before the scheduled callback has fired. We now let the timer continue to run even when the autocommand deletes itself to avoid having to repeat the cleanup code multiple times. There is no harm in letting the timer execute if the autocommand does not exist, as the pcall will catch the error.
Diffstat (limited to 'runtime/lua/vim/_meta/api.lua')
0 files changed, 0 insertions, 0 deletions