patch 8.2.1820: Vim9: crash when error happens in timer callback
Problem: Vim9: crash when error happens in timer callback.
Solution: Check that current_exception is not NULL. (closes #7100)
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index 05378fd..310934e 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -1234,6 +1234,10 @@
if (trylevel == 0)
{
+ // Just in case did_throw got set but current_exception wasn't.
+ if (current_exception == NULL)
+ did_throw = FALSE;
+
/*
* When an exception is being thrown out of the outermost try
* conditional, discard the uncaught exception, disable the conversion
diff --git a/src/version.c b/src/version.c
index a953c09..8e2115e 100644
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1820,
+/**/
1819,
/**/
1818,