summaryrefslogtreecommitdiffstats
path: root/src/spellfile.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:05:15 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:05:15 +0000
commit6e9cd6b491267e6dff3e3f3f37d8af5f28e40672 (patch)
tree35661af16c4a0ef2a9a8e225d2d5cc82605ea289 /src/spellfile.c
parentAdding upstream version 2:9.1.0496. (diff)
downloadvim-6e9cd6b491267e6dff3e3f3f37d8af5f28e40672.tar.xz
vim-6e9cd6b491267e6dff3e3f3f37d8af5f28e40672.zip
Adding upstream version 2:9.1.0698.upstream/2%9.1.0698
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/spellfile.c')
-rw-r--r--src/spellfile.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/spellfile.c b/src/spellfile.c
index 51261ab..0b9536d 100644
--- a/src/spellfile.c
+++ b/src/spellfile.c
@@ -6434,7 +6434,13 @@ init_spellfile(void)
l = (int)STRLEN(buf);
vim_snprintf((char *)buf + l, MAXPATHL - l, "/spell");
if (filewritable(buf) != 2)
- vim_mkdir(buf, 0755);
+ {
+ if (vim_mkdir(buf, 0755) != 0)
+ {
+ vim_free(buf);
+ return;
+ }
+ }
l = (int)STRLEN(buf);
vim_snprintf((char *)buf + l, MAXPATHL - l,