Skip to content

perl pipes broke sometime recently #230

Open
@chrishecker

Description

@chrishecker

I had this working with an older version of msys2, which had kind of been piecemeal updated so I can't really say a version, but then I did a full update recently and perl pipes from another executable broke. So I did a fresh install today with no packages (except what is installed by msys2-x86_64-20240727.exe) and it is still broken.

Here is the perl:

use strict;
use warnings;

# cmd /c needed to work with msys2
my $cmdline = "cmd /c \"echo hello\"";
open(my $exe, "-|", $cmdline) || die;
while(<$exe>) {
  chomp;
  print "\r$_";
}
close $exe;

The hello never shows up. It works fine with strawberry perl and cygwin perl. Occasionally after hitting ctrl-c you get a The process tried to write to a nonexistent pipe. message, but it seems sporadic.

This seems related: msys2/MSYS2-packages#2471

Thanks,
Chris

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions