Skip Menu |
 

This queue is for tickets about the Config-IniFiles CPAN distribution.

Report information
The Basics
Id: 45588
Status: resolved
Priority: 0/
Queue: Config-IniFiles

People
Owner: Nobody in particular
Requestors: cg [...] mcs.de
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 2.47
  • 2.48
Fixed in: (no value)



Subject: Failure to read config from a scalar
Download (untitled) / with headers
text/plain 624b
When passing a reference to a scalar as -file argument, Config::IniFiles failes to read the configuration using IO::Scalar. Instead, it will try to open the reference as a file. The following one-liner will reproduce the problem as will the test script attached to this report: perl -e 'use Config::IniFiles; my $data="[foo]\nbar=baz\n"; my $cfg = new Config::IniFiles -file=>\$data;' I do have IO::Scalar Version 2.110 installed. The problem seems to result from line 2043 of Version 2.48 of IniFiles.pm, where only IO::Scalar is required but the VERSION of IO::Stringy is checked. Thanks in advanve for your efforts!
Subject: test.pl
Download test.pl
text/x-perl 215b
use Config::IniFiles; my $contents = <<EOT; [dummy] foo = bar EOT my $cfg = new Config::IniFiles( -file => \$cfg_contents ); print $Config::IniFiles::VERSION, "\n"; print $IO::Scalar::VERSION, "\n";
Download (untitled) / with headers
text/plain 269b
Hi! Thanks for reporting this bug. OK, I can confirm this bug existed, and was opposed to the documented behaviour. I fixed it in the Subversion repository, and uploaded a corrected Config::IniFiles as release 2.49 to CPAN. Thanks, again. Regards, -- Shlomi Fish


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.