Hello community,

here is the log from the commit of package perl-Capture-Tiny for 
openSUSE:Factory checked in at 2013-06-06 13:08:44
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Capture-Tiny (Old)
 and      /work/SRC/openSUSE:Factory/.perl-Capture-Tiny.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-Capture-Tiny"

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-Capture-Tiny/perl-Capture-Tiny.changes      
2012-05-26 12:59:39.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-Capture-Tiny.new/perl-Capture-Tiny.changes 
2013-06-06 13:08:46.000000000 +0200
@@ -1,0 +2,29 @@
+Tue Jun  4 14:46:18 UTC 2013 - [email protected]
+
+- updated to 0.22
+ 
+   Documented:
+ 
+   - Issue tracker is now github
+ 
+   Changed:
+ 
+   - Skips tee and leak tests for closed STDIN on Perl prior to
+     5.12 when PERL_UNICODE=D.  Documented lack of support as
+     a known issue.
+ 
+   - Isolated tee subprocesses from effects of PERL_UNICODE as a
+     precaution (though this did not fix the above issue).
+ 
+   - Improved layer detection for handles proxied due to being closed
+     or tied.
+ 
+   Fixed:
+ 
+   - Nested merged captures that include an external program call no longer
+     leak STDERR to the outer scope [rt.cpan.org #79376]
+ 
+   - Work around rt.perl.org #114404 by forcing PerlIO layers back on
+     original handles [rt.cpan.org #78819]
+ 
+-------------------------------------------------------------------

Old:
----
  Capture-Tiny-0.18.tar.gz

New:
----
  Capture-Tiny-0.22.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-Capture-Tiny.spec ++++++
--- /var/tmp/diff_new_pack.ubrKHP/_old  2013-06-06 13:08:46.000000000 +0200
+++ /var/tmp/diff_new_pack.ubrKHP/_new  2013-06-06 13:08:46.000000000 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package perl-Capture-Tiny
 #
-# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           perl-Capture-Tiny
-Version:        0.18
+Version:        0.22
 Release:        0
 %define cpan_name Capture-Tiny
 Summary:        Capture STDOUT and STDERR from Perl, XS or external programs
@@ -33,7 +33,6 @@
 #BuildRequires: perl(Cases)
 #BuildRequires: perl(Inline)
 #BuildRequires: perl(Test::Differences)
-#BuildRequires: perl(Test::Requires)
 #BuildRequires: perl(TieEvil)
 #BuildRequires: perl(TieLC)
 #BuildRequires: perl(Utils)
@@ -49,11 +48,6 @@
 
 %prep
 %setup -q -n %{cpan_name}-%{version}
-# MANUAL BEGIN
-%if 0%{?sles_version} == 10 || 0%{?rhel_version} || 0%{?centos_version}
-  %{__perl} -p -i -e 's|6.31|6.30|' Makefile.PL
-%endif
-# MANUAL END 
 
 %build
 %{__perl} Makefile.PL INSTALLDIRS=vendor

++++++ Capture-Tiny-0.18.tar.gz -> Capture-Tiny-0.22.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/Changes 
new/Capture-Tiny-0.22/Changes
--- old/Capture-Tiny-0.18/Changes       2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/Changes       2013-03-27 20:50:36.000000000 +0100
@@ -1,8 +1,42 @@
 Revision history for Capture-Tiny
 
+0.22      2013-03-27 15:50:29 America/New_York
+
+  Documented:
+
+  - Issue tracker is now github
+
+0.21      2012-11-14 19:04:49 America/New_York
+
+  Changed:
+
+  - Skips tee and leak tests for closed STDIN on Perl prior to
+    5.12 when PERL_UNICODE=D.  Documented lack of support as
+    a known issue.
+
+  - Isolated tee subprocesses from effects of PERL_UNICODE as a
+    precaution (though this did not fix the above issue).
+
+  - Improved layer detection for handles proxied due to being closed
+    or tied.
+
+0.20      2012-09-19 13:20:57 America/New_York
+
+  Fixed:
+
+  - Nested merged captures that include an external program call no longer
+    leak STDERR to the outer scope [rt.cpan.org #79376]
+
+0.19      2012-08-06 20:26:34 America/New_York
+
+  Fixed:
+
+  - Work around rt.perl.org #114404 by forcing PerlIO layers back on
+    original handles [rt.cpan.org #78819]
+
 0.18      2012-05-04 16:31:53 America/New_York
 
-  Added
+  Added:
 
   - When capture or tee are called in void context, Capture::Tiny
     skips reading back from the capture handles if it can do so safely
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/MANIFEST 
new/Capture-Tiny-0.22/MANIFEST
--- old/Capture-Tiny-0.18/MANIFEST      2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/MANIFEST      2013-03-27 20:50:36.000000000 +0100
@@ -13,6 +13,7 @@
 lib/Capture/Tiny.pm
 perlcritic.rc
 t/00-compile.t
+t/00-report-prereqs.t
 t/01-Capture-Tiny.t
 t/02-capture.t
 t/03-tee.t
@@ -42,6 +43,7 @@
 xt/author/critic.t
 xt/author/pod-spell.t
 xt/release/distmeta.t
+xt/release/minimum-version.t
 xt/release/pod-coverage.t
 xt/release/pod-syntax.t
 xt/release/portability.t
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/META.json 
new/Capture-Tiny-0.22/META.json
--- old/Capture-Tiny-0.18/META.json     2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/META.json     2013-03-27 20:50:36.000000000 +0100
@@ -4,7 +4,7 @@
       "David Golden <[email protected]>"
    ],
    "dynamic_config" : 1,
-   "generated_by" : "Dist::Zilla version 4.300015, CPAN::Meta::Converter 
version 2.120630",
+   "generated_by" : "Dist::Zilla version 4.300031, CPAN::Meta::Converter 
version 2.120921",
    "license" : [
       "apache_2_0"
    ],
@@ -30,6 +30,14 @@
             "ExtUtils::MakeMaker" : "6.30"
          }
       },
+      "develop" : {
+         "requires" : {
+            "Pod::Coverage::TrustPod" : "0",
+            "Test::CPAN::Meta" : "0",
+            "Test::Pod" : "1.41",
+            "Test::Pod::Coverage" : "1.08"
+         }
+      },
       "runtime" : {
          "requires" : {
             "Carp" : "0",
@@ -38,7 +46,7 @@
             "File::Temp" : "0",
             "IO::Handle" : "0",
             "Scalar::Util" : "0",
-            "perl" : "5.006",
+            "perl" : "5.008",
             "strict" : "0",
             "warnings" : "0"
          }
@@ -49,8 +57,11 @@
          },
          "requires" : {
             "Config" : "0",
+            "ExtUtils::MakeMaker" : "0",
             "File::Find" : "0",
+            "File::Spec::Functions" : "0",
             "IO::File" : "0",
+            "List::Util" : "0",
             "Test::More" : "0.62"
          }
       }
@@ -58,22 +69,21 @@
    "provides" : {
       "Capture::Tiny" : {
          "file" : "lib/Capture/Tiny.pm",
-         "version" : "0.18"
+         "version" : "0.22"
       }
    },
    "release_status" : "stable",
    "resources" : {
       "bugtracker" : {
-         "mailto" : "bug-capture-tiny at rt.cpan.org",
-         "web" : 
"http://rt.cpan.org/Public/Dist/Display.html?Name=Capture-Tiny";
+         "web" : "https://github.com/dagolden/capture-tiny/issues";
       },
-      "homepage" : "https://github.com/dagolden/capture-tiny";,
+      "homepage" : "https://metacpan.org/release/Capture-Tiny";,
       "repository" : {
          "type" : "git",
-         "url" : "https://github.com/dagolden/capture-tiny.git";,
+         "url" : "git://github.com/dagolden/capture-tiny.git",
          "web" : "https://github.com/dagolden/capture-tiny";
       }
    },
-   "version" : "0.18"
+   "version" : "0.22"
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/META.yml 
new/Capture-Tiny-0.22/META.yml
--- old/Capture-Tiny-0.18/META.yml      2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/META.yml      2013-03-27 20:50:36.000000000 +0100
@@ -4,13 +4,16 @@
   - 'David Golden <[email protected]>'
 build_requires:
   Config: 0
+  ExtUtils::MakeMaker: 0
   File::Find: 0
+  File::Spec::Functions: 0
   IO::File: 0
+  List::Util: 0
   Test::More: 0.62
 configure_requires:
   ExtUtils::MakeMaker: 6.30
 dynamic_config: 1
-generated_by: 'Dist::Zilla version 4.300015, CPAN::Meta::Converter version 
2.120630'
+generated_by: 'Dist::Zilla version 4.300031, CPAN::Meta::Converter version 
2.120921'
 license: apache
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -27,7 +30,7 @@
 provides:
   Capture::Tiny:
     file: lib/Capture/Tiny.pm
-    version: 0.18
+    version: 0.22
 requires:
   Carp: 0
   Exporter: 0
@@ -35,11 +38,11 @@
   File::Temp: 0
   IO::Handle: 0
   Scalar::Util: 0
-  perl: 5.006
+  perl: 5.008
   strict: 0
   warnings: 0
 resources:
-  bugtracker: http://rt.cpan.org/Public/Dist/Display.html?Name=Capture-Tiny
-  homepage: https://github.com/dagolden/capture-tiny
-  repository: https://github.com/dagolden/capture-tiny.git
-version: 0.18
+  bugtracker: https://github.com/dagolden/capture-tiny/issues
+  homepage: https://metacpan.org/release/Capture-Tiny
+  repository: git://github.com/dagolden/capture-tiny.git
+version: 0.22
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/Makefile.PL 
new/Capture-Tiny-0.22/Makefile.PL
--- old/Capture-Tiny-0.18/Makefile.PL   2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/Makefile.PL   2013-03-27 20:50:36.000000000 +0100
@@ -2,7 +2,7 @@
 use strict;
 use warnings;
 
-use 5.006;
+use 5.008;
 
 use ExtUtils::MakeMaker 6.30;
 
@@ -13,8 +13,11 @@
   "AUTHOR" => "David Golden <dagolden\@cpan.org>",
   "BUILD_REQUIRES" => {
     "Config" => 0,
+    "ExtUtils::MakeMaker" => 0,
     "File::Find" => 0,
+    "File::Spec::Functions" => 0,
     "IO::File" => 0,
+    "List::Util" => 0,
     "Test::More" => "0.62"
   },
   "CONFIGURE_REQUIRES" => {
@@ -34,7 +37,7 @@
     "strict" => 0,
     "warnings" => 0
   },
-  "VERSION" => "0.18",
+  "VERSION" => "0.22",
   "test" => {
     "TESTS" => "t/*.t"
   }
@@ -58,7 +61,7 @@
   unless eval { ExtUtils::MakeMaker->VERSION(6.52) };
 
 if ( $^O eq 'MSWin32' ) {
-  $WriteMakefileArgs{PREREQ_PM}{'Win32API::File'} = '0';
+       $WriteMakefileArgs{PREREQ_PM}{'Win32API::File'} = '0';
 }
 
 WriteMakefile(%WriteMakefileArgs);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/README new/Capture-Tiny-0.22/README
--- old/Capture-Tiny-0.18/README        2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/README        2013-03-27 20:50:36.000000000 +0100
@@ -3,19 +3,31 @@
     programs
 
 VERSION
-    version 0.18
+    version 0.22
 
 SYNOPSIS
        use Capture::Tiny ':all';
  
+       # capture from external command
+ 
+       ($stdout, $stderr, $exit) = capture {
+         system( $cmd, @args );
+       };
+ 
+       # capture from arbitrary code (Perl or external)
+ 
        ($stdout, $stderr, @result) = capture {
          # your code here
        };
  
+       # capture partial or merged output
+ 
        $stdout = capture_stdout { ... };
        $stderr = capture_stderr { ... };
        $merged = capture_merged { ... };
  
+       # tee output
+ 
        ($stdout, $stderr) = tee {
          # your code here
        };
@@ -96,8 +108,8 @@
        $merged = capture_merged \&code;
 
     The "capture_merged" function works just like "capture" except STDOUT
-    and STDERR are merged. (Technically, STDERR is redirected to STDOUT
-    before executing the function.)
+    and STDERR are merged. (Technically, STDERR is redirected to the same
+    capturing handle as STDOUT before executing the function.)
 
     Caution: STDOUT and STDERR output in the merged result are not
     guaranteed to be properly ordered due to buffering.
@@ -173,6 +185,10 @@
     opened to file descriptor 0, as this causes problems on various
     platforms.
 
+    Prior to Perl 5.12, closed STDIN combined with PERL_UNICODE=D leaks
+    filehandles and also breaks tee() for undiagnosed reasons. So don't do
+    that.
+
     Localized filehandles
 
     If code localizes any of Perl's standard filehandles before capturing,
@@ -296,8 +312,8 @@
 SUPPORT
   Bugs / Feature Requests
     Please report any bugs or feature requests through the issue tracker at
-    <http://rt.cpan.org/Public/Dist/Display.html?Name=Capture-Tiny>. You
-    will be notified automatically of any progress on your issue.
+    <https://github.com/dagolden/capture-tiny/issues>. You will be notified
+    automatically of any progress on your issue.
 
   Source Code
     This is open source software. The code repository is available for
@@ -305,7 +321,7 @@
 
     <https://github.com/dagolden/capture-tiny>
 
-      git clone https://github.com/dagolden/capture-tiny.git
+      git clone git://github.com/dagolden/capture-tiny.git
 
 AUTHOR
     David Golden <[email protected]>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/dist.ini 
new/Capture-Tiny-0.22/dist.ini
--- old/Capture-Tiny-0.18/dist.ini      2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/dist.ini      2013-03-27 20:50:36.000000000 +0100
@@ -5,8 +5,14 @@
 copyright_year    = 2009
 
 [@DAGOLDEN]
+:version = 0.043
+AutoMetaResources.bugtracker.rt = 0
+AutoMetaResources.bugtracker.github = user:dagolden
 stopwords = UTF
 stopwords = seekable
+stopwords = prototyped
+stopwords = resending
+stopwords = undiagnosed
 
 [OSPrereqs / MSWin32]
 Win32API::File = 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/lib/Capture/Tiny.pm 
new/Capture-Tiny-0.22/lib/Capture/Tiny.pm
--- old/Capture-Tiny-0.18/lib/Capture/Tiny.pm   2012-05-04 22:31:58.000000000 
+0200
+++ new/Capture-Tiny-0.22/lib/Capture/Tiny.pm   2013-03-27 20:50:36.000000000 
+0100
@@ -3,7 +3,7 @@
 use warnings;
 package Capture::Tiny;
 # ABSTRACT: Capture STDOUT and STDERR from Perl, XS or external programs
-our $VERSION = '0.18'; # VERSION
+our $VERSION = '0.22'; # VERSION
 use Carp ();
 use Exporter ();
 use IO::Handle ();
@@ -26,11 +26,11 @@
   capture         => [1,1,0,0],
   capture_stdout  => [1,0,0,0],
   capture_stderr  => [0,1,0,0],
-  capture_merged  => [1,0,1,0], # don't do STDERR since merging
+  capture_merged  => [1,1,1,0],
   tee             => [1,1,0,1],
   tee_stdout      => [1,0,0,1],
   tee_stderr      => [0,1,0,1],
-  tee_merged      => [1,0,1,1], # don't do STDERR since merging
+  tee_merged      => [1,1,1,1],
 );
 
 for my $sub ( keys %api ) {
@@ -48,12 +48,12 @@
 
 my $IS_WIN32 = $^O eq 'MSWin32';
 
-#our $DEBUG = $ENV{PERL_CAPTURE_TINY_DEBUG};
-#
-#my $DEBUGFH;
-#open $DEBUGFH, "> DEBUG" if $DEBUG;
-#
-#*_debug = $DEBUG ? sub(@) { print {$DEBUGFH} @_ } : sub(){0};
+##our $DEBUG = $ENV{PERL_CAPTURE_TINY_DEBUG};
+##
+##my $DEBUGFH;
+##open $DEBUGFH, "> DEBUG" if $DEBUG;
+##
+##*_debug = $DEBUG ? sub(@) { print {$DEBUGFH} @_ } : sub(){0};
 
 our $TIMEOUT = 30;
 
@@ -63,7 +63,7 @@
 # This is annoying, but seems to be the best that can be done
 # as a simple, portable IPC technique
 #--------------------------------------------------------------------------#
-my @cmd = ($^X, '-e', '$SIG{HUP}=sub{exit}; '
+my @cmd = ($^X, '-C0', '-e', '$SIG{HUP}=sub{exit}; '
   . 'if( my $fn=shift ){ open my $fh, qq{>$fn}; print {$fh} $$; close $fh;} '
   . 'my $buf; while (sysread(STDIN, $buf, 2048)) { '
   . 'syswrite(STDOUT, $buf); syswrite(STDERR, $buf)}'
@@ -94,8 +94,8 @@
 }
 
 sub _close {
+  # _debug( "# closing " . ( defined $_[0] ? _name($_[0]) : 'undef' )  . " on 
" . fileno( $_[0] ) . "\n" );
   close $_[0] or Carp::confess "Error from close(" . join(q{, }, @_) . "): $!";
-  # _debug( "# closed " . ( defined $_[0] ? _name($_[0]) : 'undef' ) . "\n" );
 }
 
 my %dup; # cache this so STDIN stays fd0
@@ -124,7 +124,7 @@
     }
     else {
       _open \*STDOUT, ">" . File::Spec->devnull;
-      # _debug( "# proxied STDOUT as " . (defined fileno STDOUT ? fileno 
STDOUT : 'undef' ) . "\n" );
+       # _debug( "# proxied STDOUT as " . (defined fileno STDOUT ? fileno 
STDOUT : 'undef' ) . "\n" );
       _open $dup{stdout} = IO::Handle->new, ">&=STDOUT";
     }
     $proxies{stdout} = \*STDOUT;
@@ -134,11 +134,11 @@
     $proxy_count{stderr}++;
     if (defined $dup{stderr}) {
       _open \*STDERR, ">&=" . fileno($dup{stderr});
-      # _debug( "# restored proxy STDERR as " . (defined fileno STDERR ? 
fileno STDERR : 'undef' ) . "\n" );
+       # _debug( "# restored proxy STDERR as " . (defined fileno STDERR ? 
fileno STDERR : 'undef' ) . "\n" );
     }
     else {
       _open \*STDERR, ">" . File::Spec->devnull;
-      # _debug( "# proxied STDERR as " . (defined fileno STDERR ? fileno 
STDERR : 'undef' ) . "\n" );
+       # _debug( "# proxied STDERR as " . (defined fileno STDERR ? fileno 
STDERR : 'undef' ) . "\n" );
       _open $dup{stderr} = IO::Handle->new, ">&=STDERR";
     }
     $proxies{stderr} = \*STDERR;
@@ -149,7 +149,7 @@
 
 sub _unproxy {
   my (%proxies) = @_;
-  # _debug( "# unproxing " . join(" ", keys %proxies) . "\n" );
+  # _debug( "# unproxying: " . join(" ", keys %proxies) . "\n" );
   for my $p ( keys %proxies ) {
     $proxy_count{$p}--;
     # _debug( "# unproxied " . uc($p) . " ($proxy_count{$p} left)\n" );
@@ -272,7 +272,7 @@
 sub _slurp {
   my ($name, $stash) = @_;
   my ($fh, $pos) = map { $stash->{$_}{$name} } qw/capture pos/;
-  # _debug( "# slurping captured $name from $pos with layers: 
@{[PerlIO::get_layers($fh)]}\n");
+  # _debug( "# slurping captured $name from " . fileno($fh) . " at pos $pos 
with layers: @{[PerlIO::get_layers($fh)]}\n");
   seek( $fh, $pos, 0 ) or die "Couldn't seek on capture handle for $name\n";
   my $text = do { local $/; scalar readline $fh };
   return defined($text) ? $text : "";
@@ -301,8 +301,8 @@
   # find initial layers
   my %layers = (
     stdin   => [PerlIO::get_layers(\*STDIN) ],
-    stdout  => [PerlIO::get_layers(\*STDOUT)],
-    stderr  => [PerlIO::get_layers(\*STDERR)],
+    stdout  => [PerlIO::get_layers(\*STDOUT, output => 1)],
+    stderr  => [PerlIO::get_layers(\*STDERR, output => 1)],
   );
   # _debug( "# existing layers for $_\: @{$layers{$_}}\n" ) for qw/stdin 
stdout stderr/;
   # get layers from underlying glob of tied filehandles if we can
@@ -332,8 +332,8 @@
   my %proxy_std = _proxy_std();
   # _debug( "# proxy std: @{ [%proxy_std] }\n" );
   # update layers after any proxying
-  $layers{stdout} = [PerlIO::get_layers(\*STDOUT)] if $proxy_std{stdout};
-  $layers{stderr} = [PerlIO::get_layers(\*STDERR)] if $proxy_std{stderr};
+  $layers{stdout} = [PerlIO::get_layers(\*STDOUT, output => 1)] if 
$proxy_std{stdout};
+  $layers{stderr} = [PerlIO::get_layers(\*STDERR, output => 1)] if 
$proxy_std{stderr};
   # _debug( "# post-proxy layers for $_\: @{$layers{$_}}\n" ) for qw/stdin 
stdout stderr/;
   # store old handles and setup handles for capture
   $stash->{old} = _copy_std();
@@ -354,7 +354,6 @@
   my ($exit_code, $inner_error, $outer_error, @result);
   {
     local *STDIN = *CT_ORIG_STDIN if $localize{stdin}; # get original, not 
proxy STDIN
-    local *STDERR = *STDOUT if $do_merge; # minimize buffer mixups during $code
     # _debug( "# finalizing layers ...\n" );
     _relayer(\*STDOUT, $layers{stdout}) if $do_stdout;
     _relayer(\*STDERR, $layers{stderr}) if $do_stderr;
@@ -368,6 +367,9 @@
   # _debug( "# restoring filehandles ...\n" );
   _open_std( $stash->{old} );
   _close( $_ ) for values %{$stash->{old}}; # don't leak fds
+  # shouldn't need relayering originals, but see rt.perl.org #114404
+  _relayer(\*STDOUT, $layers{stdout}) if $do_stdout;
+  _relayer(\*STDERR, $layers{stderr}) if $do_stderr;
   _unproxy( %proxy_std );
   # _debug( "# killing tee subprocesses ...\n" ) if $do_tee;
   _kill_tees( $stash ) if $do_tee;
@@ -392,37 +394,51 @@
   return unless defined wantarray;
   my @return;
   push @return, $got{stdout} if $do_stdout;
-  push @return, $got{stderr} if $do_stderr;
+  push @return, $got{stderr} if $do_stderr && ! $do_merge;
   push @return, @result;
   return wantarray ? @return : $return[0];
 }
 
 1;
 
-
+__END__
 
 =pod
 
+=encoding utf-8
+
 =head1 NAME
 
 Capture::Tiny - Capture STDOUT and STDERR from Perl, XS or external programs
 
 =head1 VERSION
 
-version 0.18
+version 0.22
 
 =head1 SYNOPSIS
 
    use Capture::Tiny ':all';
  
+   # capture from external command
+ 
+   ($stdout, $stderr, $exit) = capture {
+     system( $cmd, @args );
+   };
+ 
+   # capture from arbitrary code (Perl or external)
+ 
    ($stdout, $stderr, @result) = capture {
      # your code here
    };
  
+   # capture partial or merged output
+ 
    $stdout = capture_stdout { ... };
    $stderr = capture_stderr { ... };
    $merged = capture_merged { ... };
  
+   # tee output
+ 
    ($stdout, $stderr) = tee {
      # your code here
    };
@@ -507,8 +523,8 @@
    $merged = capture_merged \&code;
 
 The C<<< capture_merged >>> function works just like C<<< capture >>> except 
STDOUT and
-STDERR are merged. (Technically, STDERR is redirected to STDOUT before
-executing the function.)
+STDERR are merged. (Technically, STDERR is redirected to the same capturing
+handle as STDOUT before executing the function.)
 
 Caution: STDOUT and STDERR output in the merged result are not guaranteed to be
 properly ordered due to buffering.
@@ -591,6 +607,9 @@
 captured to ensure that the filehandle used for capture is not opened to file
 descriptor 0, as this causes problems on various platforms.
 
+Prior to Perl 5.12, closed STDIN combined with PERL_UNICODE=D leaks filehandles
+and also breaks tee() for undiagnosed reasons.  So don't do that.
+
 B<Localized filehandles>
 
 If code localizes any of Perl's standard filehandles before capturing, the 
capture
@@ -767,7 +786,7 @@
 =head2 Bugs / Feature Requests
 
 Please report any bugs or feature requests through the issue tracker
-at L<http://rt.cpan.org/Public/Dist/Display.html?Name=Capture-Tiny>.
+at L<https://github.com/dagolden/capture-tiny/issues>.
 You will be notified automatically of any progress on your issue.
 
 =head2 Source Code
@@ -777,7 +796,7 @@
 
 L<https://github.com/dagolden/capture-tiny>
 
-  git clone https://github.com/dagolden/capture-tiny.git
+  git clone git://github.com/dagolden/capture-tiny.git
 
 =head1 AUTHOR
 
@@ -792,8 +811,3 @@
   The Apache License, Version 2.0, January 2004
 
 =cut
-
-
-__END__
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/perlcritic.rc 
new/Capture-Tiny-0.22/perlcritic.rc
--- old/Capture-Tiny-0.18/perlcritic.rc 2012-05-04 22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/perlcritic.rc 2013-03-27 20:50:36.000000000 +0100
@@ -10,7 +10,6 @@
 [-ControlStructures::ProhibitUnlessBlocks]
 [-Documentation::RequirePodSections]
 [-InputOutput::ProhibitInteractiveTest]
-[-Miscellanea::RequireRcsKeywords]
 [-References::ProhibitDoubleSigils]
 [-RegularExpressions::RequireExtendedFormatting]
 [-InputOutput::ProhibitTwoArgOpen]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/t/00-compile.t 
new/Capture-Tiny-0.22/t/00-compile.t
--- old/Capture-Tiny-0.18/t/00-compile.t        2012-05-04 22:31:58.000000000 
+0200
+++ new/Capture-Tiny-0.22/t/00-compile.t        2013-03-27 20:50:36.000000000 
+0100
@@ -70,4 +70,5 @@
             script_compiles( $file, "$script script compiles" );
         }
     }
+
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/t/00-report-prereqs.t 
new/Capture-Tiny-0.22/t/00-report-prereqs.t
--- old/Capture-Tiny-0.18/t/00-report-prereqs.t 1970-01-01 01:00:00.000000000 
+0100
+++ new/Capture-Tiny-0.22/t/00-report-prereqs.t 2013-03-27 20:50:36.000000000 
+0100
@@ -0,0 +1,72 @@
+#!perl
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+use ExtUtils::MakeMaker;
+use File::Spec::Functions;
+use List::Util qw/max/;
+
+my @modules = qw(
+  Carp
+  Config
+  Exporter
+  ExtUtils::MakeMaker
+  File::Find
+  File::Spec
+  File::Spec::Functions
+  File::Temp
+  IO::File
+  IO::Handle
+  Inline
+  List::Util
+  Scalar::Util
+  Test::More
+  perl
+  strict
+  warnings
+);
+
+# replace modules with dynamic results from MYMETA.json if we can
+# (hide CPAN::Meta from prereq scanner)
+my $cpan_meta = "CPAN::Meta";
+if ( -f "MYMETA.json" && eval "require $cpan_meta" ) { ## no critic
+  if ( my $meta = eval { CPAN::Meta->load_file("MYMETA.json") } ) {
+    my $prereqs = $meta->prereqs;
+    delete $prereqs->{develop};
+    my %uniq = map {$_ => 1} map { keys %$_ } map { values %$_ } values 
%$prereqs;
+    $uniq{$_} = 1 for @modules; # don't lose any static ones
+    @modules = sort keys %uniq;
+  }
+}
+
+my @reports = [qw/Version Module/];
+
+for my $mod ( @modules ) {
+  next if $mod eq 'perl';
+  my $file = $mod;
+  $file =~ s{::}{/}g;
+  $file .= ".pm";
+  my ($prefix) = grep { -e catfile($_, $file) } @INC;
+  if ( $prefix ) {
+    my $ver = MM->parse_version( catfile($prefix, $file) );
+    $ver = "undef" unless defined $ver; # Newer MM should do this anyway
+    push @reports, [$ver, $mod];
+  }
+  else {
+    push @reports, ["missing", $mod];
+  }
+}
+
+if ( @reports ) {
+  my $vl = max map { length $_->[0] } @reports;
+  my $ml = max map { length $_->[1] } @reports;
+  splice @reports, 1, 0, ["-" x $vl, "-" x $ml];
+  diag "Prerequisite Report:\n", map {sprintf("  %*s 
%*s\n",$vl,$_->[0],-$ml,$_->[1])} @reports;
+}
+
+pass;
+
+# vim: ts=2 sts=2 sw=2 et:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/t/08-stdin-closed.t 
new/Capture-Tiny-0.22/t/08-stdin-closed.t
--- old/Capture-Tiny-0.18/t/08-stdin-closed.t   2012-05-04 22:31:58.000000000 
+0200
+++ new/Capture-Tiny-0.22/t/08-stdin-closed.t   2013-03-27 20:50:36.000000000 
+0100
@@ -37,16 +37,29 @@
 );
 
 if ( ! $no_fork ) {
-  run_test($_) for qw(
-    tee
-    tee_scalar
-    tee_stdout
-    tee_stderr
-    tee_merged
-  );
+  # prior to 5.12, PERL_UNICODE=D causes problems when STDIN is closed
+  # before capturing.  No idea why.  Documented as a known issue.
+  if ( $] lt '5.012' && ${^UNICODE} & 24 ) {
+    diag 'Skipping tee() tests because PERL_UNICODE=D not supported';
+  }
+  else {
+    run_test($_) for qw(
+      tee
+      tee_scalar
+      tee_stdout
+      tee_stderr
+      tee_merged
+    );
+  }
+}
+
+if ( $] lt '5.012' && ${^UNICODE} & 24 ) {
+  diag 'Skipping leak test because PERL_UNICODE=D not supported';
+}
+else {
+  is( next_fd, $fd, "no file descriptors leaked" );
 }
 
-is( next_fd, $fd, "no file descriptors leaked" );
 restore_std(qw/stdin/);
 
 exit 0;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/xt/author/pod-spell.t 
new/Capture-Tiny-0.22/xt/author/pod-spell.t
--- old/Capture-Tiny-0.18/xt/author/pod-spell.t 2012-05-04 22:31:58.000000000 
+0200
+++ new/Capture-Tiny-0.22/xt/author/pod-spell.t 2013-03-27 20:50:36.000000000 
+0100
@@ -2,17 +2,21 @@
 use warnings;
 use Test::More;
 
-# generated by Dist::Zilla::Plugin::Test::PodSpelling 2.002004
+# generated by Dist::Zilla::Plugin::Test::PodSpelling 2.004003
 eval "use Test::Spelling 0.12; use Pod::Wordlist::hanekomu; 1" or die $@;
 
 
 add_stopwords(<DATA>);
-all_pod_files_spelling_ok('bin', 'lib');
+all_pod_files_spelling_ok( qw( bin lib  ) );
 __DATA__
 UTF
 seekable
+prototyped
+resending
+undiagnosed
 David
 Golden
+dagolden
 lib
 Capture
 Tiny
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/xt/release/minimum-version.t 
new/Capture-Tiny-0.22/xt/release/minimum-version.t
--- old/Capture-Tiny-0.18/xt/release/minimum-version.t  1970-01-01 
01:00:00.000000000 +0100
+++ new/Capture-Tiny-0.22/xt/release/minimum-version.t  2013-03-27 
20:50:36.000000000 +0100
@@ -0,0 +1,8 @@
+#!perl
+
+use Test::More;
+
+eval "use Test::MinimumVersion";
+plan skip_all => "Test::MinimumVersion required for testing minimum versions"
+  if $@;
+all_minimum_version_ok( qq{5.010} );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/xt/release/portability.t 
new/Capture-Tiny-0.22/xt/release/portability.t
--- old/Capture-Tiny-0.18/xt/release/portability.t      2012-05-04 
22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/xt/release/portability.t      2013-03-27 
20:50:36.000000000 +0100
@@ -5,4 +5,5 @@
 eval 'use Test::Portability::Files';
 plan skip_all => 'Test::Portability::Files required for testing portability'
     if $@;
+options(test_one_dot => 0);
 run_tests();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Capture-Tiny-0.18/xt/release/test-version.t 
new/Capture-Tiny-0.22/xt/release/test-version.t
--- old/Capture-Tiny-0.18/xt/release/test-version.t     2012-05-04 
22:31:58.000000000 +0200
+++ new/Capture-Tiny-0.22/xt/release/test-version.t     2013-03-27 
20:50:36.000000000 +0100
@@ -1,12 +1,22 @@
-#!/usr/bin/perl
-use 5.006;
 use strict;
 use warnings;
 use Test::More;
 
-use Test::Requires {
-    'Test::Version' => 0.04,
+# generated by Dist::Zilla::Plugin::Test::Version 0.002004
+BEGIN { eval "use Test::Version; 1;" or die $@; }
+
+my @imports = ( 'version_all_ok' );
+
+my $params = {
+    is_strict   => 0,
+    has_version => 1,
 };
 
+push @imports, $params
+    if version->parse( $Test::Version::VERSION ) >= version->parse('1.002');
+
+
+Test::Version->import(@imports);
+
 version_all_ok;
 done_testing;

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to