From a96ac2a086358ea0d44b9f11ead3dd3d4fe574d8 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Wed, 18 Nov 1998 03:42:26 +0000 Subject: [PATCH] Eliminate another file error in prompting. --- v7/src/edwin/filcom.scm | 6 +++--- v7/src/edwin/unix.scm | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/v7/src/edwin/filcom.scm b/v7/src/edwin/filcom.scm index a3f356299..72c5d6894 100644 --- a/v7/src/edwin/filcom.scm +++ b/v7/src/edwin/filcom.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: filcom.scm,v 1.195 1998/11/18 03:17:52 cph Exp $ +;;; $Id: filcom.scm,v 1.196 1998/11/18 03:42:26 cph Exp $ ;;; ;;; Copyright (c) 1986, 1989-98 Massachusetts Institute of Technology ;;; @@ -186,9 +186,9 @@ invocation." (event-distributor/invoke! (ref-variable find-file-hooks buffer) buffer) (load-find-file-initialization buffer pathname))) -(define (file-test-no-errors test pathname) +(define (file-test-no-errors test . args) (catch-file-errors (lambda () false) - (lambda () (test pathname)))) + (lambda () (apply test args)))) (define (file-newer-than-file? a b) (let ((a (file-modification-time-indirect a))) diff --git a/v7/src/edwin/unix.scm b/v7/src/edwin/unix.scm index 550d45a08..341c926f4 100644 --- a/v7/src/edwin/unix.scm +++ b/v7/src/edwin/unix.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: unix.scm,v 1.85 1998/10/23 05:42:24 cph Exp $ +;;; $Id: unix.scm,v 1.86 1998/11/18 03:40:46 cph Exp $ ;;; ;;; Copyright (c) 1989-98 Massachusetts Institute of Technology ;;; @@ -105,7 +105,7 @@ Includes the new backup. Must be > 0." ;; comparison, and will not notice aliases. (let ((homedir (user-homedir-pathname))) (let loop ((directory (directory-pathname pathname))) - (cond ((file-eq? directory homedir) + (cond ((file-test-no-errors file-eq? directory homedir) (string-append "~/" (->namestring (enough-pathname pathname directory)))) -- 2.25.1