Bugfix: it choked on an empty argument!
This commit is contained in:
parent
a8d754e876
commit
70083dee12
|
@ -22,7 +22,7 @@ error = 'getopt error'
|
||||||
|
|
||||||
def getopt(args, options):
|
def getopt(args, options):
|
||||||
list = []
|
list = []
|
||||||
while args and args[0][0] == '-' and args[0] <> '-':
|
while args and args[0][:1] == '-' and args[0] <> '-':
|
||||||
if args[0] == '--':
|
if args[0] == '--':
|
||||||
args = args[1:]
|
args = args[1:]
|
||||||
break
|
break
|
||||||
|
|
Loading…
Reference in New Issue