Browse thread
Pipes and Standard Output / Input on Windows
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | John Whitington <john@c...> |
| Subject: | Pipes and Standard Output / Input on Windows |
Hullo. I'm compiling OCaml command-line software with the MSVC toolchain on Windows. Users have noticed two problems: (a) When output (such as the --help) is done on Windows, the help doesn't all show (I fixed this by flushing stdout manually - but shouldn't stdout be flushed when the process exits anyway?) (b) Chaining invocations of the tool together using pipes on Windows often fails. The second process in the chain gets an End_Of_File after only a few hundred bytes of data. I've confirmed the data is all being output by the first process, and the first process is exiting cleanly. All the open_in and open_out calls are using the _bin variant. The data being sent down the pipe is a PDF file (which contains binary sections). Neither of these problems occur on Linux / Mac builds - is there something about windows pipes I should know? -- John Whitington Coherent Graphics Ltd http://www.coherentpdf.com/