Fixing Unix/Windows init-stdio

db4
Daniel Ehrenberg 2008-02-22 20:41:14 -06:00
parent 72e15848bf
commit a4963a9217
2 changed files with 3 additions and 3 deletions

View File

@ -182,7 +182,7 @@ M: unix-io io-multiplex ( ms -- )
mx get-global wait-for-events ;
M: unix-io init-stdio ( -- )
0 1 handle>duplex-stream io:stdio utf8 <encoded-duplex> set-global
0 1 handle>duplex-stream utf8 <encoded-duplex> io:stdio set-global
2 <writer> utf8 <encoded> io:stderr set-global ;
! mx io-task for embedding an fd-based mx inside another mx

View File

@ -1,7 +1,7 @@
USING: io.nonblocking io.windows threads.private kernel
io.backend windows.winsock windows.kernel32 windows
io.streams.duplex io namespaces alien.syntax system combinators
io.buffers ;
io.buffers io.encodings io.encodings.utf8 ;
IN: io.windows.ce.backend
: port-errored ( port -- )
@ -41,5 +41,5 @@ M: windows-ce-io init-stdio ( -- )
] [
0 _getstdfilex _fileno
1 _getstdfilex _fileno
] if <win32-duplex-stream>
] if <win32-duplex-stream> utf8 <encoded-duplex>
] with-variable stdio set-global ;