aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2007-12-02 18:05:36 +0000
committerGlenn Morris2007-12-02 18:05:36 +0000
commitd87fefad371af0bca0b4bed3268c1f3414d5f900 (patch)
tree637fed19abe5bb1eda0e3d2fa16f8eaf0f332be0
parented7cf49acf6f5ba065bf6556d406c470fad8c251 (diff)
downloademacs-d87fefad371af0bca0b4bed3268c1f3414d5f900.tar.gz
emacs-d87fefad371af0bca0b4bed3268c1f3414d5f900.zip
(top-level): Don't require cl when compiling.
(url-history-setup-save-timer, url-history-save-history): Use condition-case rather than ignore-errors.
-rw-r--r--lisp/url/url-history.el10
1 files changed, 6 insertions, 4 deletions
diff --git a/lisp/url/url-history.el b/lisp/url/url-history.el
index 1ed3c71174e..605ffa0145f 100644
--- a/lisp/url/url-history.el
+++ b/lisp/url/url-history.el
@@ -28,7 +28,6 @@
28 28
29;; This can get a recursive require. 29;; This can get a recursive require.
30;;(require 'url) 30;;(require 'url)
31(eval-when-compile (require 'cl))
32(require 'url-parse) 31(require 'url-parse)
33(autoload 'url-do-setup "url") 32(autoload 'url-do-setup "url")
34 33
@@ -83,8 +82,9 @@ to run the `url-history-setup-save-timer' function manually."
83(defun url-history-setup-save-timer () 82(defun url-history-setup-save-timer ()
84 "Reset the history list timer." 83 "Reset the history list timer."
85 (interactive) 84 (interactive)
86 (ignore-errors 85 (condition-case nil
87 (cancel-timer url-history-timer)) 86 (cancel-timer url-history-timer)
87 (error nil))
88 (setq url-history-timer nil) 88 (setq url-history-timer nil)
89 (if (and (eq url-history-track t) url-history-save-interval) 89 (if (and (eq url-history-track t) url-history-save-interval)
90 (setq url-history-timer (run-at-time url-history-save-interval 90 (setq url-history-timer (run-at-time url-history-save-interval
@@ -120,7 +120,9 @@ user for what type to save as."
120 (interactive) 120 (interactive)
121 (or fname (setq fname (expand-file-name url-history-file))) 121 (or fname (setq fname (expand-file-name url-history-file)))
122 (unless (file-directory-p (file-name-directory fname)) 122 (unless (file-directory-p (file-name-directory fname))
123 (ignore-errors (make-directory (file-name-directory fname)))) 123 (condition-case nil
124 (make-directory (file-name-directory fname))
125 (error nil)))
124 (cond 126 (cond
125 ((not url-history-changed-since-last-save) nil) 127 ((not url-history-changed-since-last-save) nil)
126 ((not (file-writable-p fname)) 128 ((not (file-writable-p fname))