updated for version 7.2-056
diff --git a/src/spell.c b/src/spell.c
index 4807fff..058f7d6 100644
--- a/src/spell.c
+++ b/src/spell.c
@@ -8112,7 +8112,8 @@
 		p = rr == 1 ? ftp->ft_from : ftp->ft_to;
 		l = (int)STRLEN(p);
 		putc(l, fd);
-		fwv &= fwrite(p, l, (size_t)1, fd);
+		if (l > 0)
+		    fwv &= fwrite(p, l, (size_t)1, fd);
 	    }
 	}