s3tools/s3cmd — pull request #137 by mdomsch (2013-03-09 05:40:04+00:00)
Title: fix sync single remote file to existing local file traceback, bug 88

fixes https://github.com/s3tools/s3cmd/issues/88

We were getting a traceback:

remote_list[remote_list.keys()[0]]['local_filename'] = deunicodise(destination_base)
IndexError: list index out of range

In this instance, remote_list length is 0 because the file is on the
update_list instead. We'll get to process that in a bit. The right
thing to do in _set_local_filename() is to simply return if the list
length is zero - there's nothing for us to do.