X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?p=ypp-sc-tools.db-live.git;a=blobdiff_plain;f=yarrg%2Fcommod-update-receiver;h=4ae267d9b41d3ce78e217b3d74164a0c6feda09a;hp=6fac8a27b688e659682d8d8625e2e0d4e682ace7;hb=492ee8e5d023945e2768e9568f22bd63a19b59f4;hpb=5054fcc355306f2bccdef9ea1aa8fb79488a9561 diff --git a/yarrg/commod-update-receiver b/yarrg/commod-update-receiver index 6fac8a2..4ae267d 100755 --- a/yarrg/commod-update-receiver +++ b/yarrg/commod-update-receiver @@ -25,20 +25,6 @@ # are used without permission. This program is not endorsed or # sponsored by Three Rings. -# All calls contain: -# clientname "ypp-sc-tools" -# clientversion 2.1-g2e06a26 [from git-describe --tags HEAD] -# clientfixes "lastpage" [space separated list] -# -# Timestamp requests contain: -# requesttimestamp -# -# Uploads contain: -# ocean canonical mixed case -# island canonical mixed case -# data filename=deduped.tsv.gz output of yarrg --tsv - - use strict (qw(vars)); use POSIX; use MIME::Entity; @@ -49,7 +35,7 @@ $CGI::POST_MAX= 3*1024*1024; use CGI qw/:standard -private_tempfiles/; -setlocale(LC_CTYPE, "en_GB.UTF-8"); +set_ctype_utf8(); our $now= time; defined $now or die $!; @@ -147,9 +133,10 @@ foreach my $mid (<_mid-*.hold>) { unlink $mid or $!==&ENOENT or die "$mid $!"; } +$o{'instance'}= $ENV{'YARRG_INSTANCE'}; my $mcontent= MIME::Entity->build(To => 'yarrg-commod-updates', - Subject => $pwd, + Subject => $ENV{'YARRG_INSTANCE'}, Type => 'multipart/mixed', Boundary => '=', 'Message-ID' => $mid, @@ -217,7 +204,7 @@ M->error and fail("write sendmail failed! ($!)"); $?=0; close M; $? and fail("sendmail failed code $?"); print header(-type=>'text/plain', -charset=>'us-ascii'), - "OK\n" + "OK\nThank you for your submission to YARRG.\n" or die $!; addlog("accepted $o{'clientspec'}");