more python 3.2 fixes
authorRalf Jung <post@ralfj.de>
Tue, 11 Nov 2014 10:20:39 +0000 (11:20 +0100)
committerRalf Jung <post@ralfj.de>
Tue, 11 Nov 2014 10:20:39 +0000 (11:20 +0100)
zonemaker/zone.py

index 094c0f868eee8fe19c6dc1fa4f583dfc6b3326e6..330c1842d3978440f1bf54127dc482d7062de472 100644 (file)
@@ -258,7 +258,7 @@ class Zone:
         try:
             with open(self._serialfile) as f:
                 cur_serial = int(f.read())
         try:
             with open(self._serialfile) as f:
                 cur_serial = int(f.read())
-        except FileNotFoundError:
+        except OSError: # FileNotFoundError has been added in Python 3.3
             pass
         # increment serial
         cur_serial += 1
             pass
         # increment serial
         cur_serial += 1