From 248634e90d3a9174c38a5c7a748b7913367ffc66 Mon Sep 17 00:00:00 2001 From: Lute Kamstra Date: Thu, 11 Aug 2005 13:28:47 +0000 Subject: [PATCH] (battery-status-function): Don't use ignore-errors. --- lisp/battery.el | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) 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. -- 2.39.2