Package: google-sitemapgen
Version: 1.5-2
Severity: normal

I've just fixed this bug. Patch attached.

-- System Information:
Debian Release: 6.0.1
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages google-sitemapgen depends on:
ii  python                  2.6.6-3+squeeze6 interactive high-level object-orie

google-sitemapgen recommends no packages.

google-sitemapgen suggests no packages.

-- no debconf information
--- google-sitemapgen.orig	2011-03-28 18:21:06.822343932 -0300
+++ google-sitemapgen	2011-03-28 18:22:16.714330338 -0300
@@ -62,7 +62,8 @@
 import fnmatch
 import glob
 import gzip
-import md5
+#import md5
+import hashlib
 import os
 import re
 import stat
@@ -425,7 +426,7 @@
     """ Output and count a warning.  Suppress duplicate warnings. """
     if text:
       text = encoder.NarrowText(text, None)
-      hash = md5.new(text).digest()
+      hash = hashlib.md5(text).digest()
       if not self._warns_shown.has_key(hash):
         self._warns_shown[hash] = 1
         print '[WARNING] ' + text
@@ -438,7 +439,7 @@
     """ Output and count an error.  Suppress duplicate errors. """
     if text:
       text = encoder.NarrowText(text, None)
-      hash = md5.new(text).digest()
+      hash = hashlib.md5(text).digest()
       if not self._errors_shown.has_key(hash):
         self._errors_shown[hash] = 1
         print '[ERROR] ' + text
@@ -648,8 +649,8 @@
     if not self.loc:
       return None
     if self.loc.endswith('/'):
-      return md5.new(self.loc[:-1]).digest()
-    return md5.new(self.loc).digest()
+      return hashlib.md5(self.loc[:-1]).digest()
+    return hashlib.md5(self.loc).digest()
   #end def MakeHash
 
   def Log(self, prefix='URL', level=3):

Reply via email to