original commit: 55e75b7454eb063287276d908ba5d980b229ad0a
This commit is contained in:
Matthew Flatt 2004-10-03 02:43:56 +00:00
parent 19950789d7
commit 964f823307

View File

@ -76,12 +76,6 @@
(cons dest dests))
(let ([s (make-bytes 4096)])
(let loop ()
(let ([b (peek-byte-or-special src)])
(if (or (byte? b) (eof-object? b))
;; Read-bytes-avail should work fine --- assuming
;; that no one else reads the byte, first. So we
;; have a race condition here, and the solution is
;; to add read-bytes-avail-or-special! to MzScheme
(let ([c (read-bytes-avail! s src)])
(unless (eof-object? c)
(for-each
@ -91,14 +85,7 @@
(let ([c2 (write-bytes-avail s dest start c)])
(loop (+ start c2))))))
(cons dest dests))
(loop)))
;; Got a special
(begin
(for-each
(lambda (dest)
(write-special dest b))
(cons dest dests))
(loop)))))))
(loop))))))
(define merge-input
(case-lambda