From 39c0b5b3bcd9d4cf57437d1988df834a1800c66c Mon Sep 17 00:00:00 2001 From: Justin Luth Date: Fri, 29 Dec 2017 17:12:27 +0300 Subject: [PATCH] Fix bug 10504: match download's sourceurl mangling in, updxlrator MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Updatexlrator stores its files in a hash of the URL. The download utility mangles the URL for [+/~], but the updxlrator only does it for [/]. Thus, download stores the result as one hash, and updxlrator looks for it with a different hash. The result is that the file is re-downloaded every time by both the client, and updxlrator. This is fixed by making updxlrator mangle the url in the same way as the downloader. apt-get install g++ would be a good test for this. Signed-off-by: Justin Luth  Signed-off-by: Michael Tremer --- config/updxlrator/updxlrator | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/updxlrator/updxlrator b/config/updxlrator/updxlrator index 2ddc6d8e44..b728902f6d 100644 --- a/config/updxlrator/updxlrator +++ b/config/updxlrator/updxlrator @@ -345,7 +345,9 @@ sub check_cache my $sourceurl=$_[0]; my $cfmirror=$_[4]; + $sourceurl =~ s@\%2b@+@ig; $sourceurl =~ s@\%2f@/@ig; + $sourceurl =~ s@\%7e@~@ig; $updfile = substr($sourceurl,rindex($sourceurl,"/")+1); $updfile =~ s@\%20@ @ig; -- 2.39.2