Mail Archives: cygwin/1998/06/11/19:58:03
> Earnie Boyd (earnie_boyd AT yahoo DOT com)
> Wed, 10 Jun 1998 05:39:09 -0700 (PDT)
>
>
>Hello fellow analysts,
>
>Below is a sample program demonstrating a method for piping in a WIN32
>environment. This was tested using the Mingw32 toolset.
>
>-----8<-----8<-----8<-----8<-----8<-----8<-----8<-----8<-----8<-----8<-----8<--
>/*
> testpipe.c
>
> Example of the use of a pipe in a WIN32 setting.
>
> Author: Earnie Boyd, (c) 1998
> No warranties are given, use at your own risk.
> Permission is granted to use as you wish.
>
> This program pipes the output of ls to the input of less. The
>prerequesites
> of using this program is that you have the executables for both of
>these
Your code makes an appeal to the Microsoft console, and is not the
kind of `pure' Unix-style _popen, _pclose code that you use when
porting. The semantics of the _popen and _pclose commands of crtdll.dll
indicate that they automatically provide a Unix-style setup in which
_popen launches the application that receives the piped data via its
`stdin'. I would be much more interested in seeing your version of
the latest slrn piped printer code (from John Davis's site) sending
character data to the lpr.bat published earlier this month on this
forum.
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".
- Raw text -