From 90889a692076f2c62486607d0354e0fca52364bc Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Mon, 20 Feb 2017 00:05:40 -0800 Subject: Import Upstream version 5e5 --- Tscript.scm | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) (limited to 'Tscript.scm') diff --git a/Tscript.scm b/Tscript.scm index 22b80ea..a238c61 100644 --- a/Tscript.scm +++ b/Tscript.scm @@ -1,3 +1,22 @@ +;;;; "Tscript.scm" transcript-on and transcript-off. +;; Copyright (C) 1999 Free Software Foundation, Inc. +;; +;; This program is free software: you can redistribute it and/or modify +;; it under the terms of the GNU Lesser General Public License as +;; published by the Free Software Foundation, either version 3 of the +;; License, or (at your option) any later version. +;; +;; This program is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; Lesser General Public License for more details. +;; +;; You should have received a copy of the GNU Lesser General Public +;; License along with this program. If not, see +;; . + +;;; Author: Radey Shouman + (define transcript-on #f) (define transcript-off #f) @@ -24,7 +43,9 @@ (and (input-port? port) (lambda () (let ((c (read-char port))) - (write-char c trans) + (if (eof-object? c) + (close-output-port trans) + (write-char c trans)) c))) (lambda () (close-port port))) @@ -57,4 +78,4 @@ (set! transcript-on trans-on) (set! transcript-off trans-off)) -(provide 'transcript) \ No newline at end of file +(provide 'transcript) -- cgit v1.2.3