X-Git-Url: https://git.deb.at/w?a=blobdiff_plain;f=lib%2FPackages%2FDispatcher.pm;h=998e13c3d123c5a47f4df5e7bee968119acd0deb;hb=0a9d42d1b3d812e265f38bded1b844f94fedb281;hp=08c6f96a1c7cee40a1985e2a88eeb3006908f27f;hpb=f13529a2f31d2dd523c2a5559f62c73129e3954d;p=deb%2Fpackages.git diff --git a/lib/Packages/Dispatcher.pm b/lib/Packages/Dispatcher.pm index 08c6f96..998e13c 100755 --- a/lib/Packages/Dispatcher.pm +++ b/lib/Packages/Dispatcher.pm @@ -64,12 +64,15 @@ sub do_dispatch { delete $ENV{'LC_ALL'}; delete $ENV{'LC_MESSAGES'}; - my %SUITES_ALIAS = ( oldstable => 'etch', - stable => 'lenny', - testing => 'squeeze', + my %SUITES_ALIAS = ( oldstable => 'lenny', + stable => 'squeeze', + testing => 'wheezy', unstable => 'sid', - '4.0' => 'etch', - '5.0' => 'lenny' ); + 'rc-buggy' => 'experimental', + '5.0' => 'lenny', + '6.0' => 'squeeze', + 'oldstable-backports' => 'lenny-backports', + 'stable-backports' => 'squeeze-backports' ); # Read in all the variables set by the form my $input; @@ -101,8 +104,9 @@ sub do_dispatch { $last_modified = $now if $now - $last_modified < 3600; if ($input->http('If-Modified-Since') and - (my $modtime = str2time($input->http('If-Modified-Since'), 'UTC'))) { - if ($modtime <= $last_modified) { + (my $client_timestamp = str2time($input->http('If-Modified-Since'), 'UTC'))) { + if ($client_timestamp > $last_modified) { + # we are not modified since asked -> return "304 Not Modified" print $input->header(-status => 304); exit; }