diff options
author | simonmar <unknown> | 1999-11-25 16:54:15 +0000 |
---|---|---|
committer | simonmar <unknown> | 1999-11-25 16:54:15 +0000 |
commit | 0086477cfe554f9c65ae4c2f1e4e19f4e8c063eb (patch) | |
tree | 506ffebc9496dc64bbc5cf129eea5c2ebbd533c6 /ghc/lib/std/cbits/fileLookAhead.c | |
parent | 63b4f50cfaa383118c947445e5afb4fff3cd1c91 (diff) | |
download | haskell-0086477cfe554f9c65ae4c2f1e4e19f4e8c063eb.tar.gz |
[project @ 1999-11-25 16:54:14 by simonmar]
Incremental cleanups & improvements to the I/O subsystem
- Initial fix for problems caused by partial writes
to non-blocking file descriptors. To see this bug,
run ghc/tests/programs/life_space_leak through a pipe.
- remove FILEOBJ_FLUSH, it allegedly has the same meaning
as FILEOBJ_WRITE. This fixes a buf in openFd: it erroneously didn't
set FILEOBJ_FLUSH on writeable file descriptors.
- some ANSIfication
Diffstat (limited to 'ghc/lib/std/cbits/fileLookAhead.c')
-rw-r--r-- | ghc/lib/std/cbits/fileLookAhead.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/ghc/lib/std/cbits/fileLookAhead.c b/ghc/lib/std/cbits/fileLookAhead.c index 60267df647..aa47301d6a 100644 --- a/ghc/lib/std/cbits/fileLookAhead.c +++ b/ghc/lib/std/cbits/fileLookAhead.c @@ -1,7 +1,7 @@ /* * (c) The GRASP/AQUA Project, Glasgow University, 1994-1998 * - * $Id: fileLookAhead.c,v 1.3 1998/12/02 13:27:25 simonm Exp $ + * $Id: fileLookAhead.c,v 1.4 1999/11/25 16:54:14 simonmar Exp $ * * hLookAhead Runtime Support */ @@ -10,8 +10,7 @@ #include "stgio.h" StgInt -fileLookAhead(ptr) -StgForeignPtr ptr; +fileLookAhead(StgForeignPtr ptr) { IOFileObject* fo = (IOFileObject*)ptr; int c, rc; @@ -45,9 +44,7 @@ StgForeignPtr ptr; } StgInt -ungetChar(ptr,c) -StgForeignPtr ptr; -StgChar c; +ungetChar(StgForeignPtr ptr, StgChar c) { IOFileObject* fo = (IOFileObject*)ptr; int rc = 0, sz = 0; |