From: Lute Kamstra Date: Thu, 11 Aug 2005 13:28:47 +0000 (+0000) Subject: (battery-status-function): Don't use ignore-errors. X-Git-Tag: emacs-pretest-22.0.90~7637 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=248634e90d3a9174c38a5c7a748b7913367ffc66;p=emacs.git (battery-status-function): Don't use ignore-errors. --- diff --git a/lisp/battery.el b/lisp/battery.el index 125e037719e..649cbe4c2c3 100644 --- a/lisp/battery.el +++ b/lisp/battery.el @@ -49,10 +49,11 @@ (file-directory-p "/proc/acpi/battery")) 'battery-linux-proc-acpi) ((and (eq system-type 'darwin) - (ignore-errors - (with-temp-buffer - (and (eq (call-process "pmset" nil t nil "-g" "ps") 0) - (> (buffer-size) 0))))) + (condition-case nil + (with-temp-buffer + (and (eq (call-process "pmset" nil t nil "-g" "ps") 0) + (> (buffer-size) 0))) + (error nil))) 'battery-pmset)) "*Function for getting battery status information. The function has to return an alist of conversion definitions.