summaryrefslogtreecommitdiff
path: root/src/spell.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/spell.c')
-rw-r--r--src/spell.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/spell.c b/src/spell.c
index dda81d9d5..83c232c52 100644
--- a/src/spell.c
+++ b/src/spell.c
@@ -2073,6 +2073,8 @@ count_common_word(
if (len == -1)
p = word;
+ else if (len >= MAXWLEN)
+ return;
else
{
vim_strncpy(buf, word, len);