[Israel.pm] is this a known issue - or should i look into my code??

Chanan Berler chananb at centerity.com
Thu Jan 8 08:36:54 PST 2009


Since I am kinda newbie to some of the stuff here (not so much to perl, but
the mailing list and all), I will look at the code - and try my best.
Thanks
Chanan

-----Original Message-----
From: perl-bounces at perl.org.il [mailto:perl-bounces at perl.org.il] On Behalf
Of Gaal Yahas
Sent: Thursday, January 08, 2009 6:25 PM
To: Perl in Israel
Subject: Re: [Israel.pm] is this a known issue - or should i look into my
code??

Please report this to C. J. Kirsle, the module author. Consider
including a patch that fixes the problem!

On Thu, Jan 8, 2009 at 5:10 PM, Chanan Berler <chananb at centerity.com> wrote:
> First of all, thanks for looking on the code...someone told me to check
for
> the source file over CPAN.
> I do think it's a bug, since the error came due to a break line (empty
like)
>
> My INI looked more like:
> [settings]
> Key1=value1
> Key2=value2
> <empty line>
> Key3=value3
>
> Thanks
> Chanan
>
> PS: my simple qa was by removing all the unnecessary lines...:-)
> -----Original Message-----
> From: perl-bounces at perl.org.il [mailto:perl-bounces at perl.org.il] On Behalf
> Of Gaal Yahas
> Sent: Thursday, January 08, 2009 4:56 PM
> To: Perl in Israel
> Subject: Re: [Israel.pm] is this a known issue - or should i look into my
> code??
>
> Looking at the code here:
>
>
http://search.cpan.org/src/KIRSLE/Config-INI-Simple-0.02/lib/Config/INI/Simp
> le.pm
>
> ...it appears you have a line that doesn't contain a "=" but the
> module is trying to parse it as key=value. The relevant snippet:
>
>  67                 my ($what,$is) = split(/=/, $line, 2);
>  68                 $what =~ s/^\s*//g;
>  69                 $what =~ s/\s*$//g;
>  70                 $is =~ s/^\s*//g;
>  71                 $is =~ s/\s*$//g;
>  72
>  73                 $data->{$block}->{$what} = $is;
>
> So, I think there's a bug in your ini file. Arguably, there's also a
> bug in the module, because it could have caught this condition and not
> created a config key with undef value (as it does in line 73). But
> this is a ::Simple module, which suggests both the code and the
> interface are kept simple.
>
> On Thu, Jan 8, 2009 at 4:20 PM, Chanan Berler <chananb at centerity.com>
wrote:
>> Hi All,
>>
>> I tried running script, and got this warning message:
>>
>> Use of uninitialized value in substitution (s///) at
>> /usr/lib/perl5/site_perl/5.8.8/Config/INI/Simple.pm line 70.
>>
>> I used  Config::INI::Simple module.
>> Is this a known issue, or is it mine? How can I know that? Tried google
>> it.no luck
>> Thanks
>> Chanan
>>
>> _______________________________________________
>> Perl mailing list
>> Perl at perl.org.il
>> http://perl.org.il/mailman/listinfo/perl
>>
>
>
>
> --
> Gaal Yahas <gaal at forum2.org>
> http://gaal.livejournal.com/
> _______________________________________________
> Perl mailing list
> Perl at perl.org.il
> http://perl.org.il/mailman/listinfo/perl
>
> _______________________________________________
> Perl mailing list
> Perl at perl.org.il
> http://perl.org.il/mailman/listinfo/perl
>



-- 
Gaal Yahas <gaal at forum2.org>
http://gaal.livejournal.com/
_______________________________________________
Perl mailing list
Perl at perl.org.il
http://perl.org.il/mailman/listinfo/perl




More information about the Perl mailing list