~ubuntu-branches/ubuntu/gutsy/python-dns/gutsy-security

« back to all changes in this revision

Viewing changes to debian/patches/04lazy-init.patch

  • Committer: Bazaar Package Importer
  • Author(s): Scott Kitterman
  • Date: 2007-05-11 10:29:03 UTC
  • Revision ID: james.westby@ubuntu.com-20070511102903-9qyhxe3d4cs5eera
Tags: 2.3.0-6
* New maintainer
* Acknowledge NMU, thanks Raphael Hertzog; (closes: #373528).
  - NMU also provided Python 2.4 packages (closes: #326155).
* debian/control:
  - Add Debian Python Modules Team as uploader 
  - Update standards version to 3.7.2
  - Update python-support build-depends to version (>= 0.3) and move from 
    Indep to build-depends
  - Add XS-Vcs-Svn
  - Removed XS-Python-Version and XB-Python-Version
* debian/pyversions and debian/pycompat added
* Add simple-patchsys.mk to debian/rules
* Bump compat to 5
* BTS Patches:
  - 01resolv-conf-parse patch, thanks to Arnaud Fontaine <arnaud@andesi.org> 
    (closes: #378991)
* Changes from Ubuntu (SF = Sourceforge project bug #) (closes: #411138):
  - 02utf-8 patch for files with UTF-8 content
  - 03socket-error-trap patch, Added DNSError trap for socket.error.
  - 04lazy-init SF 1563723 lazy should initilize defaults['server']
  - 05addr2bin2addr SF 863364 Mac OS X, Win2000 DHCP, addr2bin and bin2addr.
  - 06win32-fix SF 1180344 win32dns.py fails on windows server 2003
  - 07unpacker SF 954095 Bug in DNS.Lib.Unpacker.getbyte()
  - 08import-lib SF 658601 Missing "import Lib"; for TCP protocol

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
diff -Nur python-dns-2.3.0/DNS/lazy.py python-dns-2.3.0.new/DNS/lazy.py
 
2
--- python-dns-2.3.0/DNS/lazy.py        2002-05-06 02:14:38.000000000 -0400
 
3
+++ python-dns-2.3.0.new/DNS/lazy.py    2007-05-11 17:04:10.000000000 -0400
 
4
@@ -12,6 +12,7 @@
 
5
 
 
6
 def revlookup(name):
 
7
     "convenience routine for doing a reverse lookup of an address"
 
8
+    if Base.defaults['server'] == []: Base.DiscoverNameServers()
 
9
     a = string.split(name, '.')
 
10
     a.reverse()
 
11
     b = string.join(a, '.')+'.in-addr.arpa'
 
12
@@ -23,6 +24,7 @@
 
13
     convenience routine for doing an MX lookup of a name. returns a
 
14
     sorted list of (preference, mail exchanger) records
 
15
     """
 
16
+    if Base.defaults['server'] == []: Base.DiscoverNameServers()
 
17
     a = Base.DnsRequest(name, qtype = 'mx').req().answers
 
18
     l = map(lambda x:x['data'], a)
 
19
     l.sort()