From 66c78c957c878374bf44e80a123a9daf34fcea83 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 3 Apr 2012 08:18:58 -0500 Subject: [PATCH] Import version as of 2012-04-03 for upload-ftp-v1.1.pl --- upload-ftp-v1.1.pl | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/upload-ftp-v1.1.pl b/upload-ftp-v1.1.pl index bdca276..de9308d 100755 --- a/upload-ftp-v1.1.pl +++ b/upload-ftp-v1.1.pl @@ -522,7 +522,7 @@ sub email_addresses { my @ret; open (EMAIL_FILE, "<", "$package_config_base/$package_name/email") - || &fatal("The directory line should start with the name of the package for which you are trying to upload a file, e.g. gcc, gawk, or gasm. We have no package named '$package_name'.",1); + || &fatal("The directory line should start with the name of the package for which you are trying to upload a file, e.g. gcc, gawk, or emacs. We have no package named '$package_name'.",1); while () { chomp; @@ -705,7 +705,11 @@ sub read_directive_file { # Phone home. E-mail the contents of the directive file to the maintainer, # for debugging purposes. After this point, we don't need to pass the # $directive_file_contents to any subsequent &fatal calls. - debug($directive_file_contents) if $DEBUG; + if (defined $info{'package'}) { + debug($directive_file_contents, $info{'package'}) if $DEBUG; + } else { + debug($directive_file_contents, '') if $DEBUG; + } # They have to specify a directory directive. if (!$info{"directory"}) { @@ -931,11 +935,6 @@ sub check_files { # Verify that the file has been correctly signed with a valid signature. my @verify_args = ("/usr/bin/gpgv", "--keyring", $keyring, $sig_file, $upload_file); - - my $verify_str = join(' ',@verify_args); - ($verify_str) = $verify_str =~ /^(.*)$/; - ftp_syslog('info',"$verify_str\n") if ($DEBUG > 0); - if (!system (@verify_args)) { $valid = 1; last; @@ -1236,9 +1235,10 @@ sub mail { sub debug { my $msg = shift; + my $package_name = shift; if ($NOMAIL) { - ftp_syslog('info', "($log_style) Subject: [$m_style gnu-ftp-debug] new upload processed\nBody: $msg"); + ftp_syslog('info', "($log_style) Subject: [$m_style gnu-ftp-debug] new upload processed: $package_name\nBody: $msg"); } else { my $smtp = Net::SMTP->new ("127.0.0.1"); ftp_die("FATAL: SMTP connection failed") unless $smtp; @@ -1249,7 +1249,7 @@ sub debug { $smtp->datasend ("To: $maintainer_email\n"); $smtp->datasend ("From: ftp-upload-script\@gnu.org\n"); $smtp->datasend ("Reply-To: ftp-upload\@gnu.org\n"); - $smtp->datasend ("Subject: [$m_style gnu-ftp-debug] new upload processed"); + $smtp->datasend ("Subject: [$m_style gnu-ftp-debug] new upload processed: $package_name"); $smtp->datasend ("\n\n"); $smtp->datasend ("$msg\n"); $smtp->dataend (); -- 2.25.1