[packages/rpm-build-tools] do not send our filenames to remote server

glen glen at pld-linux.org
Thu May 8 11:19:03 CEST 2014


commit 68062e541c0e9b60a89b142396986d9d0a5fa99b
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Thu May 8 12:17:52 2014 +0300

    do not send our filenames to remote server

 update-geoip.sh | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/update-geoip.sh b/update-geoip.sh
index 84b33d2..20d27eb 100755
--- a/update-geoip.sh
+++ b/update-geoip.sh
@@ -43,7 +43,10 @@ update_urls() {
 	t=$(mktemp)
 	builder -su $specfile > $t 2>/dev/null
 	while read url; do
+		# take output filename (anything after last slash)
 		fn=${url##*/}
+		# remove querystring for mtime match to work
+		url=${url%\?*}
 		test -e "$fn" && z= || unset z
 		curl ${z+-z "$fn"} -o "$fn" "$url" -R -s
 	done < $t
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rpm-build-tools.git/commitdiff/0428aa351d502d54f543b2d81b3575d744fc1768



More information about the pld-cvs-commit mailing list