Browse Source
[downloader/http] xattr values should be bytes
master
Yen Chi Hsuan
8 years ago
No known key found for this signature in database
GPG Key ID: 3FDDD575826C5C30
1 changed files with
1 additions and
1 deletions
-
youtube_dl/downloader/http.py
|
@ -182,7 +182,7 @@ class HttpFD(FileDownloader): |
|
|
|
|
|
|
|
|
if self.params.get('xattr_set_filesize', False) and data_len is not None: |
|
|
if self.params.get('xattr_set_filesize', False) and data_len is not None: |
|
|
try: |
|
|
try: |
|
|
write_xattr(tmpfilename, 'user.ytdl.filesize', str(data_len)) |
|
|
|
|
|
|
|
|
write_xattr(tmpfilename, 'user.ytdl.filesize', str(data_len).encode('utf-8')) |
|
|
except (XAttrUnavailableError, XAttrMetadataError) as err: |
|
|
except (XAttrUnavailableError, XAttrMetadataError) as err: |
|
|
self.report_error('unable to set filesize xattr: %s' % str(err)) |
|
|
self.report_error('unable to set filesize xattr: %s' % str(err)) |
|
|
|
|
|
|
|
|