delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/10/06/08:51:32

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
To: cygwin AT cygwin DOT com
Subject: Regression problem in cygwin1.5.18 and Perl 5.8.6/7
MIME-Version: 1.0
From: Jurgen Defurne <jurgen DOT defurne AT philips DOT com>
Message-ID: <OF1F645448.FBE9A17F-ONC1257092.00445E1F-C1257092.004685F8@philips.com>
Date: Thu, 6 Oct 2005 14:48:23 +0200
X-IsSubscribed: yes

Here is a description of my problem. I have two different
installations of Cygwin on different systems :

System 1                      System 2
--------                      --------
cygwin 1.5.11-1               cygwin 1.5.18-1
perl   5.8.5-3                perl   5.8.6-4 (or 5.8.7-..)
Windows 2000                  Windows 2003 Server
Windows XP

I have certain programs which run the following code (very condensed)
as a wrapper program :

    open $proc, "$cmd|";

    while (<$proc>) {
          # E.g.
          print $_;
    }

    close $proc;

Under system 1 (the old system) this does what it must do, regardless
if I run Cygwin programs or Windows programs. I can catch the output
of the subprocess and do something with it in parallel in the 'while'
loop (eg. write the output to a log file, and to STDOUT and process it
to extract data).

I have now installed a new environment on Windows 2003 server,
and what now happens is that the output of the started process
is only read and processed after the subprocess terminates.

Nothing else has changed, the scripts which do all the work
are exactly the same.

I have tested the above code on both systems and watched the
processes with procexp. What strikes me as odd is that on the first
system have a process tree like this :

    perl
    sh
        sh
            perl (In case I start ActiveState Perl here)

On the second system I have a process tree like :

    perl
    sh
        perl (like above)

This issue is not blocking for me, because I can run the necessary
programs without my Perl wrapper, but the wrapper adds functionality
which cannot be added to the program being run.

Any ideas ?

Regards,

Jurgen

--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019