changeset 22031:f33de1c1eb4a v8.2.1565

patch 8.2.1565: spellfile test sometimes fails Commit: https://github.com/vim/vim/commit/e90d63ea904187ecbb09d0f7f21b71b302b30644 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Sep 2 12:58:48 2020 +0200 patch 8.2.1565: spellfile test sometimes fails Problem: Spellfile test sometimes fails. Solution: Check running into the end of the file.
author Bram Moolenaar <Bram@vim.org>
date Wed, 02 Sep 2020 13:00:03 +0200
parents 8b0a2216a70e
children 089b4044883f
files src/spellfile.c src/version.c
diffstat 2 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/spellfile.c
+++ b/src/spellfile.c
@@ -3533,8 +3533,7 @@ spell_read_dic(spellinfo_T *spin, char_u
     spin->si_msg_count = 999999;
 
     // Read and ignore the first line: word count.
-    (void)vim_fgets(line, MAXLINELEN, fd);
-    if (!vim_isdigit(*skipwhite(line)))
+    if (vim_fgets(line, MAXLINELEN, fd) || !vim_isdigit(*skipwhite(line)))
 	semsg(_("E760: No word count in %s"), fname);
 
     /*
--- a/src/version.c
+++ b/src/version.c
@@ -755,6 +755,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    1565,
+/**/
     1564,
 /**/
     1563,