in reply to Re: Use of uninitialized value in open second time but not first.
in thread Use of uninitialized value in open second time but not first.

open my $UTF, '>:encoding(UTF-16LE)', \$unicode16Str;

That may be a completely different issue.

  • Comment on Re^2: Use of uninitialized value in open second time but not first.
  • Download Code

Replies are listed 'Best First'.
Re^3: Use of uninitialized value in open second time but not first.
by GrandFather (Saint) on Jun 05, 2007 at 10:17 UTC

    I don't think so. The warning is only issued for the second open. The code otherwise works as expected. Initialising the output buffer ($unicode16Str) resolves the issue. Making the output buffer global also resolves the issue.


    DWIM is Perl's answer to Gödel