Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com From: "Herb Martin" To: Subject: FW: Cygwin perl hangs with open FH, "... |" Date: Mon, 15 Aug 2005 11:50:42 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-ID: X-Sign-LQC: HerbM AT learnquick DOT com/2005-08-15 11:50:28/=vygkzqmy I received a (welcome) off-list reply to my report of trouble running CygWin Perl and piping the output of an open FILEHANDLE call to capture the output. Interesting his reproduction of the problem uses other programs so it is NOT just netsh (although these could conceivably be unrelated it seems doubtful). (FYI: I am avoiding the problem by redirecting the output to a temporary file then reading in the results -- obviously not as clean a solution: my $ipsec = '/tmp/ipsxxxx.txt'; system "netsh ipsec static show all format=table >$ipsec"; open IPSEC, "<$ipsec" or die "Cannot open $ipsec: $!\n"; ) The offlist message is attached inline (with permission) here: From: Jerome Zago [mailto:] Sent: Monday, August 15, 2005 11:06 AM To: Herb Martin Subject: RE: Cygwin perl hangs with open FH, "... |" Hi, I can reproduce this problem, and this used to work before as well. Cygwin, GNU bash, Perl: same versions. ccm: 6.3 SP4 ruby: 1.8.2 [i386-mswin32] jza AT W1566$ ccm rt -show info 'COM9:Insulated Development' | wc 13 48 481 jza AT W1566$ perl -e "open FH, 'ccm rt -show info \'COM9:Insulated Development\' |'; print while " | wc 13 48 481 jza AT W1566$ ccm rt -list | wc 631 1896 37229 jza AT W1566$ perl -e "open FH, 'ccm rt -list |'; print while " | wc [hangs] jza AT W1566$ perl -e "open FH, 'ruby -e \'system \"ccm rt -list\"\' |'; print while " | wc 631 1896 37229 I don't get it... Note that ccm and ruby are both native binaries. Feel free to forward this message to the mailing-list (I'm not subscribed). -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/