--- debarchiver.pl	2013-09-23 17:59:03.000000000 +0100
+++ debarchiver	2013-09-24 15:46:57.000000000 +0100
@@ -1913,6 +1913,13 @@
     # OVERRIDES
 
     foreach my $distr (split /\s+/, $distrd) {
+
+	# Do a reverse mapping of the distribution here so we always
+	# speak the same language. i.e. testing, unstable etc. instead
+	# of jessie, sid etc.
+	my %distlookup = reverse %distmapping;
+	$distr = $distlookup{$distr} || $distr;
+
 	# Note to autoscan that files are installed to this dir.
 	$dests{"$distr/$major/$archsec"} = 1;
 
