patch 8.2.2730: Coverity complains about not restoring character
Problem: Coverity complains about not restoring character.
Solution: Also restore the character in case of an error.
diff --git a/src/version.c b/src/version.c
index 8d44824..5850872 100644
--- a/src/version.c
+++ b/src/version.c
@@ -751,6 +751,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 2730,
+/**/
2729,
/**/
2728,
diff --git a/src/vim9compile.c b/src/vim9compile.c
index c9ca595..feb1838 100644
--- a/src/vim9compile.c
+++ b/src/vim9compile.c
@@ -6108,6 +6108,7 @@
{
// this should not happen
emsg(_(e_missbrac));
+ var_start[varlen] = c;
return FAIL;
}
var_start[varlen] = c;