diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2017-02-20 00:05:40 -0800 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2017-02-20 00:05:40 -0800 |
commit | 90889a692076f2c62486607d0354e0fca52364bc (patch) | |
tree | 9c7f78885db5b48bf1e3ed132b5fabc20e25592e /Tscript.scm | |
parent | 710a97992705d67c3ded0d4b270c5978ce29b11f (diff) | |
download | scm-90889a692076f2c62486607d0354e0fca52364bc.tar.gz scm-90889a692076f2c62486607d0354e0fca52364bc.zip |
Import Upstream version 5e5upstream/5e5
Diffstat (limited to 'Tscript.scm')
-rw-r--r-- | Tscript.scm | 25 |
1 files changed, 23 insertions, 2 deletions
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 +;; <http://www.gnu.org/licenses/>. + +;;; 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) |