From f4adf50648b30350394f6f8ec3a107cbdb3a9e89 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Mon, 19 Dec 1994 21:06:39 +0000 Subject: [PATCH] In COPY-FILE, move mode-setting statement after closing of output file. This is required under OS/2, since setting the file modes is prohibited for a file that is opened for writing. --- v7/src/runtime/sfile.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/v7/src/runtime/sfile.scm b/v7/src/runtime/sfile.scm index eca51fa47..b7607f4b2 100644 --- a/v7/src/runtime/sfile.scm +++ b/v7/src/runtime/sfile.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Id: sfile.scm,v 14.14 1994/11/20 05:06:56 cph Exp $ +$Id: sfile.scm,v 14.15 1994/12/19 21:06:39 cph Exp $ Copyright (c) 1988-94 Massachusetts Institute of Technology @@ -98,11 +98,11 @@ MIT in each case. |# (if (= n-read buffer-length) (+ (loop (- source-length buffer-length)) buffer-length) - n-read))))))) - (set-file-modes! to (file-modes from))) + n-read)))))))) (lambda () (if output-channel (channel-close output-channel)) - (if input-channel (channel-close input-channel))))))) + (if input-channel (channel-close input-channel))))) + (set-file-modes! output-filename (file-modes input-filename)))) (define (file-eq? x y) ((ucode-primitive file-eq?) (->namestring (merge-pathnames x)) -- 2.25.1