Changeset 1778ab1cb1dc9b8e47928c28ca96938b4d47e28d
- Timestamp:
- 04/08/08 22:11:31
(7 months ago)
- Author:
- Jason Michalski <armooo@armooo.net>
- git-committer:
- Jason Michalski <armooo@armooo.net> 1207710691 -0500
- git-parent:
[f15900aefc8ba09915196185fd3f9895c1532600]
- git-author:
- Jason Michalski <armooo@armooo.net> 1207710520 -0500
- Message:
Made the local file name safe for windows
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| rbcdc845 |
r1778ab1 |
|
| 116 | 116 | |
|---|
| 117 | 117 | path = settings['path'] |
|---|
| 118 | | file_name = os.path.join(path, '%s-%s' % (data['bodyOfferId'] ,data['url'].split('/')[-1])) |
|---|
| | 118 | file_name = os.path.join(path, '%s-%s' % (data['bodyOfferId'].replace(':', '-'),data['url'].split('/')[-1])) |
|---|
| 119 | 119 | |
|---|
| 120 | 120 | self.downloadFile(data['url'], file_name) |
|---|
| … | … | |
| 164 | 164 | return |
|---|
| 165 | 165 | else: |
|---|
| 166 | | self.__logger.debug('File was not done byut could not resume. %s' % url) |
|---|
| | 166 | self.__logger.debug('File was not done but could not resume. %s' % url) |
|---|
| 167 | 167 | outfile.close() |
|---|
| 168 | 168 | outfile = open(file_path, 'wb') |
|---|