1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00

Use with-demoted-errors now that it can format any error messages

* dframe.el (dframe-timer-fn):
* files.el (dir-locals-read-from-file):
* mpc.el (mpc--status-timer-run, mpc--status-idle-timer-run, mpc-format):
* reveal.el (reveal-post-command):
* saveplace.el (load-save-place-alist-from-file):
* shell.el (shell-resync-dirs):
* w32-common-fns.el (x-get-selection-value):
* emacs-lisp/copyright.el (copyright-find-copyright):
* emacs-lisp/eldoc.el (eldoc-print-current-symbol-info):
* emulation/tpu-edt.el (tpu-copy-keyfile):
* play/bubbles.el (bubbles--mark-neighbourhood):
* progmodes/executable.el (executable-make-buffer-file-executable-if-script-p):
* term/pc-win.el (x-get-selection-value): Use with-demoted-errors.
This commit is contained in:
Glenn Morris 2013-09-11 22:32:57 -07:00
parent 170266d096
commit 30213927b6
14 changed files with 133 additions and 138 deletions

View file

@ -491,10 +491,9 @@ to call FUN for any change whatsoever.")
(cancel-timer mpc--status-timer)
(setq mpc--status-timer nil)))
(defun mpc--status-timer-run ()
(condition-case err
(when (process-get (mpc-proc) 'ready)
(with-local-quit (mpc-status-refresh)))
(error (message "MPC: %s" err))))
(with-demoted-errors "MPC: %s"
(when (process-get (mpc-proc) 'ready)
(with-local-quit (mpc-status-refresh)))))
(defvar mpc--status-idle-timer nil)
(defun mpc--status-idle-timer-start ()
@ -520,9 +519,8 @@ to call FUN for any change whatsoever.")
(run-with-idle-timer 10 t 'mpc--status-idle-timer-run))))
(defun mpc--status-idle-timer-run ()
(when (process-get (mpc-proc) 'ready)
(condition-case err
(with-local-quit (mpc-status-refresh))
(error (message "MPC: %s" err))))
(with-demoted-errors "MPC: %s"
(with-local-quit (mpc-status-refresh))))
(mpc--status-timer-start))
(defun mpc--status-timers-refresh ()
@ -999,9 +997,8 @@ If PLAYLIST is t or nil or missing, use the main playlist."
(`Cover
(let* ((dir (file-name-directory (cdr (assq 'file info))))
(cover (concat dir "cover.jpg"))
(file (condition-case err
(mpc-file-local-copy cover)
(error (message "MPC: %s" err))))
(file (with-demoted-errors "MPC: %s"
(mpc-file-local-copy cover)))
image)
;; (debug)
(push `(equal ',dir (file-name-directory (cdr (assq 'file info)))) pred)