X-Git-Url: https://git.ralfj.de/zonemaker.git/blobdiff_plain/bacbf61b6595b9b8f733ea26be95b1ce45cdfb45..574d9328bf51c40877ffb9766b87f27a246e8dc2:/zonemaker/zone.py?ds=sidebyside diff --git a/zonemaker/zone.py b/zonemaker/zone.py index 094c0f8..add2bde 100644 --- a/zonemaker/zone.py +++ b/zonemaker/zone.py @@ -258,7 +258,7 @@ class Zone: try: with open(self._serialfile) as f: cur_serial = int(f.read()) - except FileNotFoundError: + except (OSError, IOError): # FileNotFoundError has been added in Python 3.3 pass # increment serial cur_serial += 1