Anyway, in most cases, the proper execution of 
piping requires that you explicitly call your .EXE file. 
You can't rely on extension/application association. 

Thus your command line should be 

        out.exe | perl.exe in.pl

or at best 

        out.exe | perl in.pl


_____________________________________________
Bruno Bellenger
Sr. Network/Systems Administrator 


        -----Original Message-----
        From:   $Bill Luebkert [SMTP:[EMAIL PROTECTED]]
        Sent:   Thursday, August 29, 2002 2:21 PM
        To:     Dr.-Ing. Torsten Finke
        Cc:     [EMAIL PROTECTED]
        Subject:        Re: select on Win NT

        Dr.-Ing. Torsten Finke wrote:
        > Hi there
        >  
        > has anybody tried to check the readability of a pipe via the
select
        > command running ActivePerl under Windows NT? 
        > 
        > The following code is running fine in Linux, but select seems not
to
        > do what it should in Win NT. 
        > 
        > I ran that program in a pipeline with an executable out.exe that
        > writes (and flushes) to stdout: 
        > 
        > out.exe | in.pl
        > 
        > 
        > Regards
        > 
        > 
        > Torsten
        > 
        > 
        > <Program name="in.pl">
        > $rin = $win = $ein = '';
        > vec($rin,fileno(STDIN),1) = 1;
        > vec($win,fileno(STDOUT),1) = 1;
        > $ein = $rin | $win;
        > 
        > while ( 1 ) {
        >     $nfound = select($rout=$rin, undef, undef, 0.2);
        >     if ( $nfound ) {
        >         $c = sysread STDIN, $l, 1000; 
        >     }
        > }
        > </Program>

        select only works on sockets in Win32.

        -- 
           ,-/-  __      _  _         $Bill Luebkert   ICQ=162126130
          (_/   /  )    // //       DBE Collectibles   Mailto:[EMAIL PROTECTED]
           / ) /--<  o // //      http://dbecoll.tripod.com/ (Free site for
Perl)
        -/-' /___/_<_</_</_     Castle of Medieval Myth & Magic
http://www.todbe.com/

        _______________________________________________
        Perl-Win32-Users mailing list
        [EMAIL PROTECTED]
        To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

_______________________________________________
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to