projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
140d8d7
)
[http] Avoid closing stdout (Fixes #3686)
author
Sergey M․
<dstftw@gmail.com>
Fri, 5 Sep 2014 15:05:36 +0000
(22:05 +0700)
committer
Sergey M․
<dstftw@gmail.com>
Fri, 5 Sep 2014 15:05:36 +0000
(22:05 +0700)
youtube_dl/downloader/http.py
patch
|
blob
|
history
diff --git
a/youtube_dl/downloader/http.py
b/youtube_dl/downloader/http.py
index d01d1897e411fc5005c15868b46cfdf174c2ca4c..6caf7451ed99a00511c56cc4a7c6cb7711601ff0 100644
(file)
--- a/
youtube_dl/downloader/http.py
+++ b/
youtube_dl/downloader/http.py
@@
-193,7
+193,8
@@
class HttpFD(FileDownloader):
self.to_stderr(u"\n")
self.report_error(u'Did not get any data blocks')
return False
- stream.close()
+ if tmpfilename != u'-':
+ stream.close()
self.report_finish(data_len_str, (time.time() - start))
if data_len is not None and byte_counter != data_len:
raise ContentTooShortError(byte_counter, int(data_len))