diff options
author | Pete Zaitcev <zaitcev@kotori.zaitcev.us> | 2015-02-18 19:38:05 -0700 |
---|---|---|
committer | Pete Zaitcev <zaitcev@kotori.zaitcev.us> | 2015-02-18 19:46:41 -0700 |
commit | fec5d068a0056f5d9ec60e5fd3bbfad9b9f13b86 (patch) | |
tree | c5e5ccaf10b40fbb5d37fb9cb6703502e0309164 /swiftclient/client.py | |
parent | 8aff0bda9c35ab96146f4f419803e62710ab5618 (diff) | |
download | python-swiftclient-fec5d068a0056f5d9ec60e5fd3bbfad9b9f13b86.tar.gz |
Fix crash with -l, -d /, and pseudo folders
Using -l, -d /, or a pseduo folder by itself works fine, but if you
combine all of them, this happens:
[zaitcev@guren s]$ swift list -d / testcont
amazon_lili.jpg
pseudodir/
rin_shibuya_pixiv.jpg
swift-c134855-5a.diff
[zaitcev@guren s]$ swift list -d / -l testcont
151954 2014-06-20 17:13:52 amazon_lili.jpg
Traceback (most recent call last):
File "/q/zaitcev/hail/python-swiftclient-tip/bin/swift", line 24, in <module>
sys.exit(main())
File "/q/zaitcev/hail/python-swiftclient-tip/swiftclient/shell.py", line 1301, in main
globals()['st_%s' % args[0]](parser, argv[1:], output)
File "/q/zaitcev/hail/python-swiftclient-tip/swiftclient/shell.py", line 414, in st_list
total_bytes += item_bytes
TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'
The patch is a straightforward fix that assigns expected variables.
Change-Id: If24dcc2491e8b8982455107d2aca30c0491a398a
Closes-Bug: 1399678
Diffstat (limited to 'swiftclient/client.py')
0 files changed, 0 insertions, 0 deletions