From d29a70fedf23be94461b27c0d238e3598772594b Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 12 Jul 2002 23:24:36 +0000 Subject: [PATCH] (ediff-test-patch-utility): Catch error and return nil. --- lisp/ediff-ptch.el | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/lisp/ediff-ptch.el b/lisp/ediff-ptch.el index 0b6bc49e290..29174ff8e97 100644 --- a/lisp/ediff-ptch.el +++ b/lisp/ediff-ptch.el @@ -85,12 +85,14 @@ See also `ediff-backup-specs'." :group 'ediff-ptch) (defun ediff-test-patch-utility () - (cond ((zerop (call-process ediff-patch-program nil nil nil "-z." "-b")) - ;; GNU `patch' v. >= 2.2 - 'gnu) - ((zerop (call-process ediff-patch-program nil nil nil "-b")) - 'posix) - (t 'traditional))) + (condition-case nil + (cond ((zerop (call-process ediff-patch-program nil nil nil "-z." "-b")) + ;; GNU `patch' v. >= 2.2 + 'gnu) + ((zerop (call-process ediff-patch-program nil nil nil "-b")) + 'posix) + (t 'traditional)) + (file-error nil))) (defcustom ediff-backup-specs (let ((type (ediff-test-patch-utility))) -- 2.39.5