change the default oldversion to trunk; prevent a crash on files with 0 lines.
This commit is contained in:
parent
3fabe86aa9
commit
bc4e1d8f3b
1 changed files with 3 additions and 1 deletions
|
@ -744,6 +744,8 @@ def is_map(filename):
|
||||||
has_map_content = len(lines) > 1
|
has_map_content = len(lines) > 1
|
||||||
except OSError:
|
except OSError:
|
||||||
has_map_content = False
|
has_map_content = False
|
||||||
|
except IndexError:
|
||||||
|
has_map_content = False
|
||||||
return has_map_content
|
return has_map_content
|
||||||
|
|
||||||
class maptransform_error:
|
class maptransform_error:
|
||||||
|
@ -970,7 +972,7 @@ if __name__ == '__main__':
|
||||||
except getopt.GetoptError:
|
except getopt.GetoptError:
|
||||||
help()
|
help()
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
oldversion = 'older'
|
oldversion = 'trunk'
|
||||||
dryrun = False
|
dryrun = False
|
||||||
future = False
|
future = False
|
||||||
verbose = 0
|
verbose = 0
|
||||||
|
|
Loading…
Add table
Reference in a new issue