sub go { print "Working area is \"$directory\"\n"; $version_text= "Iteration $version[0], " . ($version[2] ? "Revision $version[2]" : "initial release") . ($version[3] ? ", Patch $version[3]" : ""); print "Version stamp: $version_text\n"; if ($option eq 'checkout') { my $database; ###### DECLARE HERE $database= new Win32::OLE:: "SourceSafe"; my $copy= $source_safe_repository; # OLE doesn't like magic variables $database->Open ($copy); } my $eachfile= sub { # on entry, $_ is name alone return unless /\.cxx$/ || /\.cpp$/ || /\.h$/ || /\.hpp$/; my $fname= $File::Find::name; $fname =~ tr[/][\\]; eval { process_file ($fname, $database); ##### USE HERE }; if ($@) { print "* An error was encountered processing \"$fname\". Error text is:\n$@\n"; } }; my $filter= sub { return grep {$_ ne "Dependant_Libs" && !/\.OUT\./} @_; }; find ({wanted => $eachfile, preprocess => $filter}, $directory); print '=' x 50, "\n"; }