match existing eof behavior
This commit is contained in:
parent
5f30e61907
commit
4022553dc0
4
vm.scm
4
vm.scm
|
@ -320,7 +320,7 @@
|
|||
; - 1 stdin
|
||||
; - 2 argument data
|
||||
; - 3 spacer between arguments
|
||||
; - 4 spacer after arguments
|
||||
; - 4 spacer after arguments, or end of stdin
|
||||
(define (u:send-input c type)
|
||||
(let* ((hi (vector-ref dev 16))
|
||||
(lo (vector-ref dev 17))
|
||||
|
@ -334,7 +334,7 @@
|
|||
(define (u:read-stdin port)
|
||||
(let ((c (read-char port)))
|
||||
(if (eof-object? c)
|
||||
(u:send-input #\newline 4)
|
||||
(u:send-input #\null 4)
|
||||
(begin
|
||||
(u:send-input c 1)
|
||||
(u:read-stdin port)))))
|
||||
|
|
Loading…
Reference in New Issue