Do you know where your variables are? | |
PerlMonks |
Re: Reading .cfg fileby afoken (Chancellor) |
on Jul 18, 2009 at 10:29 UTC ( [id://781300]=note: print w/replies, xml ) | Need Help?? |
This ... my $rc = do($file); ... is extremely dangerous. The .cfg file is EXECUTED as Perl code. Imagine a config file containing one or more of the following lines:
See also: Re^2: conf file in Perl syntax, Re: reading commands from configuration file Alexander
-- Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
In Section
Seekers of Perl Wisdom
|
|