hi list,
i write a module for MARS, the content mamagemant system,
an easy thing failed:
here my test mod:
---
package Config;
require Exporter;
@ISA = qw(Exporter);
@EXPORT = qw( new );
sub new
{
my %CONFIG;
open(CNF, "./api.cnf");
while(<CNF>)
{
next if($_ =~ /^\#/);
($bef, $var)= split(/=/);
chomp($bef, $var);
$CONFIG{$bef} = $var;
}
close(CFN);
return(%CONFIG);
}
1;
-----
and i call it :
----
use MARS::Config;
%CONFIG = Config->new;
----
The Hash is filled ok, but if i do this with a eval statemant,
i get back an error too:
BAD FILE DESCRIPTOR.
I do not understand it, because the hash is filled alright !
What does the code mean ?
_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-web