mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-14546: Fix the argument handling in Tools/scripts/lll.py (GH-13026)
This commit is contained in:
parent
0d5864fa07
commit
c4e78b116f
3 changed files with 42 additions and 4 deletions
|
@ -13,8 +13,7 @@ def lll(dirname):
|
|||
full = os.path.join(dirname, name)
|
||||
if os.path.islink(full):
|
||||
print(name, '->', os.readlink(full))
|
||||
def main():
|
||||
args = sys.argv[1:]
|
||||
def main(args):
|
||||
if not args: args = [os.curdir]
|
||||
first = 1
|
||||
for arg in args:
|
||||
|
@ -22,7 +21,7 @@ def main():
|
|||
if not first: print()
|
||||
first = 0
|
||||
print(arg + ':')
|
||||
lll(arg)
|
||||
lll(arg)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
main(sys.argv[1:])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue