/var/isconf/lib/perl5/Isconf.pm
"Stephen Schaefer" <[email protected]>
| Newsgroups | gmane.comp.sysutils.isconf.devel |
|---|---|
| Message-ID | <[email protected]> |
I'm trying to use ISconf3 on a linux box. This is not the last
portability problem I've encountered, but I need to go home :-).
When Isconf.pm runs /var/isconf/conf/init.conf on a Linux box, some of
the environment variables can be reported as empty lists. In my
instance, I had a couple:
GROUPS=()
DIRS=()
Isconf.pm confused those values with function definitions, and thought
it had come to the end of what it cared about. So may I suggest:
***************
*** 83,89 ****
/IFS/ and next; # we know we don't need to import IFS,
and it's got a carriage return
($var,$value) = split /=/ or next;
unless ($value) { next; }
! $value =~ /\(\)/ and last; # we don't want function
definitions
$value =~ s/^['"]//;
$value =~ s/['"]$//;
debug("$var is [$value]");
--- 83,90 ----
/IFS/ and next; # we know we don't need to import IFS,
and it's got a carriage return
($var,$value) = split /=/ or next;
unless ($value) { next; }
! $value =~ /.\(\)/ and last; # we don't want function
definitions
! # BUT! don't confuse with
empty list
$value =~ s/^['"]//;
$value =~ s/['"]$//;
debug("$var is [$value]");
-------------------------------------------------------
This SF.NET email is sponsored by: FREE SSL Guide from Thawte
are you planning your Web Server Security? Click here to get a FREE
Thawte SSL guide and find the answers to all your SSL security issues.
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en