[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 44bb59f: Ensure that the game directory exists before trying to w
From: |
Lars Ingebrigtsen |
Subject: |
master 44bb59f: Ensure that the game directory exists before trying to write to it |
Date: |
Tue, 22 Sep 2020 11:33:00 -0400 (EDT) |
branch: master
commit 44bb59f79e7ea7928b12a1f3eb8b5ada0265c1d0
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
Ensure that the game directory exists before trying to write to it
* lisp/play/gamegrid.el (gamegrid-add-score-insecure): Make the
directory if it doesn't exist (bug#37836).
---
lisp/play/gamegrid.el | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lisp/play/gamegrid.el b/lisp/play/gamegrid.el
index 9b74eb9..74e6c2d 100644
--- a/lisp/play/gamegrid.el
+++ b/lisp/play/gamegrid.el
@@ -635,6 +635,8 @@ FILE is created there."
(save-excursion
(setq file (expand-file-name file (or directory
temporary-file-directory)))
+ (unless (file-exists-p (file-name-directory file))
+ (make-directory (file-name-directory file) t))
(find-file-other-window file)
(setq buffer-read-only nil)
(goto-char (point-max))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 44bb59f: Ensure that the game directory exists before trying to write to it,
Lars Ingebrigtsen <=