|
Lines 137-153
Link Here
|
| 137 |
sub getValue { |
137 |
sub getValue { |
| 138 |
my $self = shift; |
138 |
my $self = shift; |
| 139 |
my $confVal = shift; |
139 |
my $confVal = shift; |
| 140 |
my $makeconf = getParamFromFile( getFileContents("/etc/make.conf"), |
140 |
my $filedata = getFileContents("/etc/make.globals").getFileContents("/etc/make.conf"); |
| 141 |
"$confVal", "lastseen" ); |
141 |
my $param = getParamFromFile($filedata,$confVal,"lastseen"); |
| 142 |
if ( !$makeconf ) { |
|
|
| 143 |
$makeconf = getParamFromFile( getFileContents("/etc/make.globals"), |
| 144 |
"$confVal", "lastseen" ); |
| 145 |
} |
| 146 |
|
142 |
|
| 147 |
if ( !$makeconf ) { |
143 |
while ($param =~m/\$\{(.+)\}/) |
|
|
144 |
{ |
| 145 |
my $fetchparam=getParamFromFile($filedata,$1,"lastseen"); |
| 146 |
$param=~s/\$\{$1\}/$fetchparam/; |
| 147 |
} |
| 148 |
|
| 149 |
if ( !$param ) { |
| 148 |
return undef; |
150 |
return undef; |
| 149 |
} |
151 |
} |
| 150 |
$self->{ lc($confVal) } = $makeconf; |
152 |
$self->{ lc($confVal) } = $param; |
| 151 |
} |
153 |
} |
| 152 |
|
154 |
|
| 153 |
sub DESTROY { |
155 |
sub DESTROY { |