samba_dnsupdate: Raise proper exception when getting unexpected DNS reply.
authorJelmer Vernooij <jelmer@samba.org>
Mon, 12 Mar 2012 18:25:39 +0000 (19:25 +0100)
committerJelmer Vernooij <jelmer@samba.org>
Tue, 13 Mar 2012 12:07:03 +0000 (13:07 +0100)
source4/scripting/bin/samba_dnsupdate

index fee1a08f4fca6850c7fbc6acef652ad56a6b3a89..076bc328b79d181a8e95106222a2fa284edc27ff 100755 (executable)
@@ -142,8 +142,7 @@ class dnsobj(object):
         elif self.type == 'NS':
             self.dest = list[2].lower()
         else:
-            print "Received unexpected DNS reply of type %s" % self.type
-            raise
+            raise Exception("Received unexpected DNS reply of type %s" % self.type)
 
     def __str__(self):
         if d.type == "A":     return "%s %s %s" % (self.type, self.name, self.ip)