source:
trunk/dports/www/sitemap_gen/files/patch-sitemap_gen_py.diff
@
125959
Last change on this file since 125959 was 87969, checked in by and.damore@…, 8 years ago | |
---|---|
File size: 1.2 KB |
-
sitemap_gen.py
62 62 import fnmatch 63 63 import glob 64 64 import gzip 65 import md565 import hashlib 66 66 import os 67 67 import re 68 68 import stat … … 425 425 """ Output and count a warning. Suppress duplicate warnings. """ 426 426 if text: 427 427 text = encoder.NarrowText(text, None) 428 hash = md5.new(text).digest()428 hash = hashlib.md5(text).digest() 429 429 if not self._warns_shown.has_key(hash): 430 430 self._warns_shown[hash] = 1 431 431 print '[WARNING] ' + text … … 438 438 """ Output and count an error. Suppress duplicate errors. """ 439 439 if text: 440 440 text = encoder.NarrowText(text, None) 441 hash = md5.new(text).digest()441 hash = hashlib.md5(text).digest() 442 442 if not self._errors_shown.has_key(hash): 443 443 self._errors_shown[hash] = 1 444 444 print '[ERROR] ' + text … … 648 648 if not self.loc: 649 649 return None 650 650 if self.loc.endswith('/'): 651 return md5.new(self.loc[:-1]).digest()652 return md5.new(self.loc).digest()651 return hashlib.md5(self.loc[:-1]).digest() 652 return hashlib.md5(self.loc).digest() 653 653 #end def MakeHash 654 654 655 655 def Log(self, prefix='URL', level=3):
Note: See TracBrowser
for help on using the repository browser.