159 sub wanted
160 {
161 my $file = $File::Find::name;
162
163 #
164 # We only care about files.
165 #
166 return if ( -d $file );
####
167
168 #
169 # Skip some mailboxes.
170 #
171 foreach my $exclude ( split( /,/, $CONFIG{'exclude'} ) )
####
172 {
173 if ( $file =~ /$exclude/i )
####
174 {
175 $CONFIG{'verbose'} && print "Excluded mail file: $file\n";
176 return;
177 }
178 }
179
180
181 #
182 # Skip files if they've not been modified too recently.
183 #
184 my $time = -M $file;
185 if ( defined( $time ) )
186 {
187 if ( $time > $CONFIG{'time'} )
188 {
189 $CONFIG{'verbose'} && print "Mail file not modified recently: $file\n";
190 return;
191 }
192 }
193 else
194 {
195 $CONFIG{'verbose'} && print "Failed to stat: $file - $!\n";
####
196 return;
197 }