X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/36280399db0ae203d3f1ae4d44b946f31e9a38ce..7db98f31498a85da22cc00e446bce8ac8c319554:/cmdline/apt-report-mirror-failure?ds=sidebyside diff --git a/cmdline/apt-report-mirror-failure b/cmdline/apt-report-mirror-failure index 70b16cf4f..1567e78e3 100755 --- a/cmdline/apt-report-mirror-failure +++ b/cmdline/apt-report-mirror-failure @@ -4,18 +4,19 @@ import sys import urllib import apt_pkg -print "apt-report-mirror-failure" - apt_pkg.init() -url = apt_pkg.Config.Find("Acquire::Mirror::ReportFailures", - "http://people.ubuntu.com:9000/mirror-failure") +url = apt_pkg.Config.Find("Acquire::Mirror::ReportFailures", None) + #"http://people.ubuntu.com:9000/mirror-failure") #"http://localhost:9000/mirror-failure") if not url: sys.exit(0) +print "Reporting mirror failure to '%s'" % url + data = {} -data['url'] = sys.argv[1] -data['error'] = sys.argv[2] +data['mirror'] = sys.argv[1] +data['failurl'] = sys.argv[2] +data['error'] = sys.argv[3] f = urllib.urlopen(url, urllib.urlencode(data)) f.read() f.close()