Subversion Repositories DevTools

Rev

Rev 1040 | Rev 5398 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1040 Rev 2571
Line 99... Line 99...
99
		    next if /^[\t\w]+#/;
99
		    next if /^[\t\w]+#/;
100
		    s/#.*//;
100
		    s/#.*//;
101
 
101
 
102
		    my ($key, $val) = trimstr split '=', $_, 2;
102
		    my ($key, $val) = trimstr split '=', $_, 2;
103
		    next unless defined $val;
103
		    next unless defined $val;
-
 
104
 
-
 
105
            #
-
 
106
            #   Create hash of key : value
-
 
107
            #   Special handling of int_list. Multiple definitions are allowed
-
 
108
            #
-
 
109
            if ( exists $conf->{$key} ) {
-
 
110
                if ( exists $pdata->{$key} && $pdata->{$key}{'fmt'} eq 'int_list' ) {
-
 
111
                    $conf->{$key} = join (' ', $conf->{$key} ,$val);
-
 
112
                } else {
-
 
113
                    push @errors, "Multiple configuration of: $key";
-
 
114
                }
-
 
115
            } else {
104
		    $conf->{$key} = $val;
116
                $conf->{$key} = $val;
-
 
117
            }
105
	    }
118
	    }
106
	    close $fh;
119
	    close $fh;
107
 
120
 
108
        #
121
        #
109
        #   Validate mandatory entries
122
        #   Validate mandatory entries
Line 172... Line 185...
172
                next;
185
                next;
173
            }
186
            }
174
 
187
 
175
            if ( $fmt eq 'size' ) {
188
            if ( $fmt eq 'size' ) {
176
                $conf->{$key} = toBytes( $data );
189
                $conf->{$key} = toBytes( $data );
-
 
190
 
177
            } elsif ( $fmt eq 'period' ) {
191
            } elsif ( $fmt eq 'period' ) {
178
                $conf->{$key} = timeToSecs( $data );
192
                $conf->{$key} = timeToSecs( $data );
179
 
193
 
180
            } elsif ( $fmt eq 'dir' ) {
194
            } elsif ( $fmt eq 'dir' ) {
181
                if ( ! -d $data ) {
195
                if ( ! -d $data ) {