Diff for /foxridge-archiver/unarchiver.pl between versions 1.4 and 1.7

version 1.4, 2005/03/23 12:12:08 version 1.7, 2008/09/10 12:59:45
Line 18  $|=1; Line 18  $|=1;
 #  #
   
 # program version  # program version
 my $version = "0.3 (20.1.2005)";  my $version = "0.3.3 (10.9.2008)";
   
 # read command line parameters  # read command line parameters
 my $args = parseargs;  my $args = parseargs;
Line 196  sub run_retrieve { Line 196  sub run_retrieve {
     # destination dir is mount point      # destination dir is mount point
     $archparent = $archmount;      $archparent = $archmount;
     }      }
       logger("INFO", "looking for archives in $archmount...");
   
     print LOG "START unarchive $version on ", scalar localtime, "\n";      print LOG "START unarchive $version on ", scalar localtime, "\n";
     my $archcmd = $archprog;      my $archcmd = $archprog;
Line 204  sub run_retrieve { Line 205  sub run_retrieve {
     $archcmd .= " '$archmount/'"; # archive mount point      $archcmd .= " '$archmount/'"; # archive mount point
     $archcmd .= " '$archparent/'"; # destination dir name      $archcmd .= " '$archparent/'"; # destination dir name
   
       logger('INFO', "querying TSM server for $archmount, please wait...");
   
     my $archcnt = 0;      my $archcnt = 0;
     my $numfiles = 0;      my $numfiles = 0;
     print LOG "CMD: $archcmd\n";      print LOG "CMD: $archcmd\n";
Line 296  sub check_files { Line 299  sub check_files {
 logger("INFO", "unarchiver $version");  logger("INFO", "unarchiver $version");
   
 # make shure the right user is running this program  # make shure the right user is running this program
 my $user = getlogin;  my $user = getlogin || getpwuid($<);
 if (($user)&&($user ne "archive")&&($user ne "root")) {  if (($user)&&($user ne "archive")&&($user ne "root")) {
     logger("ABORT", "you must be archive or root user to run this program!");      logger("ABORT", "you must be archive or root user to run this program!");
     exit 1;      exit 1;

Removed from v.1.4  
changed lines
  Added in v.1.7


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>