Ignore:
Timestamp:
2009-02-05T10:06:24+13:00 (15 years ago)
Author:
davidb
Message:

Warning about file copying in event that a hard link operation is not supported altered to only appear if verbosity > 2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gsdl/trunk/perllib/util.pm

    r18441 r18463  
    358358# make hard link to file if supported by OS, otherwise copy the file
    359359sub hard_link {
    360     my ($src, $dest) = @_;
     360    my ($src, $dest, $verbosity) = @_;
    361361
    362362    # remove trailing slashes from source and destination files
     
    386386
    387387    } elsif (!link($src, $dest)) {
    388     print STDERR "util::hard_link: unable to create hard link. ";
    389     print STDERR " Attempting to copy file: $src -> $dest\n";
     388    if ((!defined $verbosity) || ($verbosity>2)) {
     389        print STDERR "util::hard_link: unable to create hard link. ";
     390        print STDERR " Copying file: $src -> $dest\n";
     391    }
    390392    &File::Copy::copy ($src, $dest);
    391393    }
Note: See TracChangeset for help on using the changeset viewer.