BrowserUk,

Thank you very much indeed.

I was able to use fileno to output the integer value associated with STDOUT just prior to the open call [as well as just prior to the subroutine call which contains said open call]

modified Builder.pm with diagnostic print statements

sub _dup_stdhandles { my $self = shift; print STDERR "\n\n******* [chkpt1]BrowserUk diagnostic STDOUT file +no: ",fileno(STDOUT)," *******\n\n"; $self->_open_testhandles; # Set everything to unbuffered else plain prints to STDOUT will # come out in the wrong order from our own prints. _autoflush($Testout); _autoflush( \*STDOUT ); _autoflush($Testerr); _autoflush( \*STDERR ); $self->reset_outputs; return; } sub _open_testhandles { my $self = shift; return if $self->{Opened_Testhandles}; print STDERR "\n\n******* [chkpt2]BrowserUk diagnostic STDOUT file +no: ",fileno(STDOUT)," *******\n\n"; # We dup STDOUT and STDERR so people can change them in their # test suites while still getting normal test output. open( $Testout, ">&STDOUT" ) or die "Can't dup STDOUT: $!"; open( $Testerr, ">&STDERR" ) or die "Can't dup STDERR: $!"; $self->_copy_io_layers( \*STDOUT, $Testout ); $self->_copy_io_layers( \*STDERR, $Testerr ); $self->{Opened_Testhandles} = 1; return; }

installation attempt which triggers the diagnostic print

>cpan Path::Tiny Reading 'C:\Users\jndt\.cpan\Metadata' Database was generated on Tue, 22 Mar 2016 13:53:38 GMT Running install for module 'Path::Tiny' Checksum for C:\Users\jndt\.cpan\sources\authors\id\D\DA\DAGOLDEN\Path +-Tiny-0.084.tar.gz ok 'YAML' not installed, will not store persistent state Configuring D/DA/DAGOLDEN/Path-Tiny-0.084.tar.gz with Makefile.PL Checking if your kit is complete... Looks good Generating a nmake-style Makefile Writing Makefile for Path::Tiny Writing MYMETA.yml and MYMETA.json DAGOLDEN/Path-Tiny-0.084.tar.gz C:\perl-5.20.3\bin\perl.exe Makefile.PL -- OK Running make for D/DA/DAGOLDEN/Path-Tiny-0.084.tar.gz ---- Unsatisfied dependencies detected during ---- ---- DAGOLDEN/Path-Tiny-0.084.tar.gz ---- Unicode::UTF8 [requires,optional] Test::MockRandom [build_requires,optional] Test::FailWarnings [build_requires,optional] Microsoft (R) Program Maintenance Utility Version 14.00.23824.1 Copyright (C) Microsoft Corporation. All rights reserved. cp lib/Path/Tiny.pm blib\lib\Path\Tiny.pm DAGOLDEN/Path-Tiny-0.084.tar.gz "C:\Program Files\Microsoft Visual Studio 14.0\VC\BIN\nmake.EXE" -- +OK Running make test Microsoft (R) Program Maintenance Utility Version 14.00.23824.1 Copyright (C) Microsoft Corporation. All rights reserved. C:\perl-5.20.3\bin\perl.exe "-MExtUtils::Command::MM" "-MTest: +:Harness" "-e" "undef *Test::Harness::Switches; test_harness(0 , 'blib\lib', 'blib\arch')" t/*.t t/00-report-prereqs.t ............. ******* [chkpt1]BrowserUk diagnostic STDOUT fileno: 1 ******* ******* [chkpt2]BrowserUk diagnostic STDOUT fileno: 1 ******* Can't dup STDOUT: Bad file descriptor at C:/perl-5.20.3/lib/Test/Buil +der.pm line 1952. Compilation failed in require at C:/perl-5.20.3/lib/Test/Builder/Modul +e.pm line 5. BEGIN failed--compilation aborted at C:/perl-5.20.3/lib/Test/Builder/M +odule.pm line 5. Compilation failed in require at C:/perl-5.20.3/lib/Test/More.pm line +23. BEGIN failed--compilation aborted at C:/perl-5.20.3/lib/Test/More.pm l +ine 23. Compilation failed in require at t/00-report-prereqs.t line 8. BEGIN failed--compilation aborted at t/00-report-prereqs.t line 8. t/00-report-prereqs.t ............. Dubious, test returned 9 (wstat 23 +04, 0x900) No subtests run t/basename.t ...................... ******* [chkpt1]BrowserUk diagnostic STDOUT fileno: 1 ******* ******* [chkpt2]BrowserUk diagnostic STDOUT fileno: 1 ******* ...

observations

So, although the STDOUT is 1 - the fact that printing to it yields no output; signifies something is definitely wrong with it.

Thanks again for your help - I feel much better about it now and I learned a new function.

Cheers,
Shadowsong


In reply to Re^2: Bad file descriptor error in Win32 VC2015 compiled perl-5.20.3 by shadowsong
in thread Bad file descriptor error in Win32 VC2015 compiled perl-5.20.3 by shadowsong

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.