Changeset 16551
- Timestamp:
- Feb 19, 2008, 3:55:58 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branch_20080219/PS-IPP-Config/lib/PS/IPP/Config.pm
r16542 r16551 1 1 # Copyright (c) 2006 Paul Price, Joshua Hoblitt 2 2 # 3 # $Id: Config.pm,v 1.75.2. 1 2008-02-19 20:09:09eugene Exp $3 # $Id: Config.pm,v 1.75.2.2 2008-02-20 01:55:58 eugene Exp $ 4 4 5 5 package PS::IPP::Config; … … 96 96 bless $self, $class; 97 97 98 print "load site\n";99 98 $self->load_site(); 100 101 print "load system\n";102 99 $self->load_system(); 103 100 … … 154 151 155 152 my $i = 0; 156 print "$i"; $i ++;157 153 158 154 unless (defined $self) { … … 160 156 exit($PS_EXIT_PROG_ERROR); 161 157 } 162 print "$i"; $i ++;163 158 164 159 my $filename = metadataLookupStr($self->{_userConfig}, 'SITE'); # Site config file … … 167 162 exit($PS_EXIT_CONFIG_ERROR); 168 163 } 169 print "$i"; $i ++;170 164 171 165 my $realfile = $self->_find_config($filename); # Resolved filename, after hunting the PATH 172 print "$i"; $i ++;173 166 174 167 # Read the file … … 178 171 exit($PS_EXIT_CONFIG_ERROR); 179 172 } 180 print "$i"; $i ++;181 173 182 174 my @contents = <$file>; 183 175 close $file; 184 176 $self->{_siteConfig} = $parser->parse( join '', @contents); # The parsed metadata config 185 print "$i"; $i ++; 186 187 ## XXXX : the error is here 177 188 178 unless (defined $self->{_siteConfig}) { 189 carp "Failure to define site configuration"; 190 exit($PS_EXIT_CONFIG_ERROR); 191 } 192 print "$i"; $i ++; 193 194 # XXX why isn't just $self being returned here? -JH 179 carp "Failure to parse the site configuration file $realfile"; 180 exit($PS_EXIT_CONFIG_ERROR); 181 } 182 195 183 return $self; 196 184 }
Note:
See TracChangeset
for help on using the changeset viewer.
