[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs-25 d90ab1e: Fix typo in eww-make-unique-file-name
From: |
Lars Ingebrigtsen |
Subject: |
[Emacs-diffs] emacs-25 d90ab1e: Fix typo in eww-make-unique-file-name |
Date: |
Thu, 04 Feb 2016 05:06:27 +0000 |
branch: emacs-25
commit d90ab1e2215cd7afbc1957a4928b3a35931cd425
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>
Fix typo in eww-make-unique-file-name
* lisp/net/eww.el (eww-make-unique-file-name): Make this function
actually work.
---
lisp/net/eww.el | 30 +++++++++++++++---------------
1 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/lisp/net/eww.el b/lisp/net/eww.el
index 7cb324e..6872be4 100644
--- a/lisp/net/eww.el
+++ b/lisp/net/eww.el
@@ -1469,21 +1469,21 @@ Differences in #targets are ignored."
string)))
(defun eww-make-unique-file-name (file directory)
- (cond
- ((zerop (length file))
- (setq file "!"))
- ((string-match "\\`[.]" file)
- (setq file (concat "!" file))))
- (let ((count 1)
- (stem file)
- (suffix ""))
- (when (string-match "\\`\\(.*\\)\\([.][^.]+\\)" file)
- (setq stem (match-string 1)
- suffix (match-string 2)))
- (while (file-exists-p (expand-file-name file directory))
- (setq file (format "%s(%d)%s" stem count suffix))
- (setq count (1+ count)))
- (expand-file-name file directory)))
+ (cond
+ ((zerop (length file))
+ (setq file "!"))
+ ((string-match "\\`[.]" file)
+ (setq file (concat "!" file))))
+ (let ((count 1)
+ (stem file)
+ (suffix ""))
+ (when (string-match "\\`\\(.*\\)\\([.][^.]+\\)" file)
+ (setq stem (match-string 1 file)
+ suffix (match-string 2)))
+ (while (file-exists-p (expand-file-name file directory))
+ (setq file (format "%s(%d)%s" stem count suffix))
+ (setq count (1+ count)))
+ (expand-file-name file directory)))
(defun eww-set-character-encoding (charset)
"Set character encoding to CHARSET.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] emacs-25 d90ab1e: Fix typo in eww-make-unique-file-name,
Lars Ingebrigtsen <=