[Python-modules-commits] r16754 - in packages/namebench/trunk/debian (5 files)

nomadium-guest at users.alioth.debian.org nomadium-guest at users.alioth.debian.org
Sun Apr 24 18:49:16 UTC 2011


    Date: Sunday, April 24, 2011 @ 18:49:00
  Author: nomadium-guest
Revision: 16754

* Simplify rules file even more.
* Re-add patch for #594146.

Added:
  packages/namebench/trunk/debian/patches/
  packages/namebench/trunk/debian/patches/594146.diff
  packages/namebench/trunk/debian/patches/series
Modified:
  packages/namebench/trunk/debian/changelog
  packages/namebench/trunk/debian/rules

Modified: packages/namebench/trunk/debian/changelog
===================================================================
--- packages/namebench/trunk/debian/changelog	2011-04-24 16:50:59 UTC (rev 16753)
+++ packages/namebench/trunk/debian/changelog	2011-04-24 18:49:00 UTC (rev 16754)
@@ -1,4 +1,4 @@
-namebench (1.3.1+dfsg-2) UNRELEASED; urgency=low
+namebench (1.3.1+dfsg-1miguel1) UNRELEASED; urgency=low
 
   * Switch from dh_pysupport to dh_python2.
   * Simplify rules file.
@@ -8,13 +8,15 @@
   * Python transition:
     - Add support for python2.7.
     - Drop support for python2.5.
+  * Decode GeoIP results with the correct encoding to avoid crashes.
+    (Closes: #594146).
   * Drop versioned dependencies since they are satisfied even in stable.
   * Make copyright file DEP-5 compliant.
   * Move comments from README.source to copyright file.
   * Simplify watch file.
   * Small fixes in Description and manpage.
 
- -- Miguel Landaeta <miguel at miguel.cc>  Fri, 22 Apr 2011 20:32:15 -0430
+ -- Miguel Landaeta <miguel at miguel.cc>  Sun, 24 Apr 2011 13:54:47 -0430
 
 namebench (1.3.1+dfsg-1) unstable; urgency=low
 

Added: packages/namebench/trunk/debian/patches/594146.diff
===================================================================
--- packages/namebench/trunk/debian/patches/594146.diff	                        (rev 0)
+++ packages/namebench/trunk/debian/patches/594146.diff	2011-04-24 18:49:00 UTC (rev 16754)
@@ -0,0 +1,16 @@
+Description: Decode GeoIP results with the correct encoding to avoid crashes
+Author: Miguel Landaeta <miguel at miguel.cc>
+Forwarded: no
+Last-Update: 2011-04-24
+
+--- namebench-1.3.1+dfsg.orig/libnamebench/geoip.py
++++ namebench-1.3.1+dfsg/libnamebench/geoip.py
+@@ -57,6 +57,8 @@ def GetFromMaxmindJSAPI():
+   h = httplib2.Http(tempfile.gettempdir(), timeout=10)
+   unused_resp, content = h.request('http://j.maxmind.com/app/geoip.js', 'GET')
+   keep = ['region_name', 'country_name', 'city', 'latitude', 'longitude', 'country_code']
++  # GeoIP lookups results are encoded in latin1, please see http://bugs.debian.org/bug=594146
++  content = content.decode('ISO-8859-1')
+   results = dict([x for x in re.findall("geoip_(.*?)\(.*?\'(.*?)\'", content) if x[0] in keep])
+   results.update({'source': 'mmind'})
+   if results:

Added: packages/namebench/trunk/debian/patches/series
===================================================================
--- packages/namebench/trunk/debian/patches/series	                        (rev 0)
+++ packages/namebench/trunk/debian/patches/series	2011-04-24 18:49:00 UTC (rev 16754)
@@ -0,0 +1 @@
+594146.diff

Modified: packages/namebench/trunk/debian/rules
===================================================================
--- packages/namebench/trunk/debian/rules	2011-04-24 16:50:59 UTC (rev 16753)
+++ packages/namebench/trunk/debian/rules	2011-04-24 18:49:00 UTC (rev 16754)
@@ -4,7 +4,7 @@
 	dh $@ --with python2
 
 override_dh_auto_install:
-	python setup.py install --root debian/tmp --install-layout=deb
+	dh_auto_install --destdir=debian/tmp
 	rm debian/tmp/usr/lib/python*/*-packages/namebench.py
 
 override_dh_auto_build:




More information about the Python-modules-commits mailing list