X-Git-Url: https://git.donarmstrong.com/?p=debbugs.git;a=blobdiff_plain;f=scripts%2Fservice;h=0059ef76df79bd1d5811163611bcc2219d7d6134;hp=4346e36e96206586f82e3e3d9518975610f45a90;hb=611a4b401fce2979a485476787afb136acf86af9;hpb=04d8d896dabc0b9314127a704b6f285a9fe54ecc diff --git a/scripts/service b/scripts/service index 4346e36..0059ef7 100755 --- a/scripts/service +++ b/scripts/service @@ -7,6 +7,9 @@ use warnings; use strict; +use locale; +use POSIX qw(strftime locale_h); +setlocale(LC_TIME, "C"); use Debbugs::Config qw(:globals :config); @@ -282,7 +285,7 @@ for ($procline=0; $procline<=$#bodylines; $procline++) { } elsif (m/^subscribe/i) { print {$transcript} <= 5) { print {$transcript} "Too many unknown commands, stopping here.\n\n"; @@ -505,7 +509,7 @@ if (!defined $header{'subject'} || $header{'subject'} eq "") { } # Error text here advertises how many errors there were -my $error_text = $errors > 0 ? " (with $errors errors)":''; +my $error_text = $errors > 0 ? " (with $errors error" . ($errors > 1 ? "s" : "") . ")" : ""; my @common_headers; push @common_headers, 'X-Loop',$gMaintainerEmail; @@ -575,7 +579,7 @@ sub fill_template{ }; my $hole_var = {'&bugurl' => sub{"$_[0]: ". - 'http://'.$config{cgi_domain}.'/'. + $config{cgi_domain}.'/'. Debbugs::CGI::bug_links(bug=>$_[0], links_only => 1, ); @@ -897,7 +901,7 @@ END sub sendlynxdocraw { my ($relpath,$description) = @_; $doc=''; - open(L,"lynx -nolist -dump http://$gCGIDomain/\Q$relpath\E 2>&1 |") || die "fork for lynx: $!"; + open(L,"lynx -nolist -dump $gCGIDomain/\Q$relpath\E 2>&1 |") || die "fork for lynx: $!"; while() { $doc.=$_; } $!=0; close(L); if ($? == 255 && $doc =~ m/^\n*lynx: Can\'t access start file/) {