projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
eb99a7e
)
Fix os.makedirs in Windows
author
Philipp Hagemeister
<phihag@phihag.de>
Tue, 6 Sep 2011 15:56:05 +0000
(17:56 +0200)
committer
Philipp Hagemeister
<phihag@phihag.de>
Tue, 6 Sep 2011 15:56:05 +0000
(17:56 +0200)
youtube-dl
patch
|
blob
|
history
diff --git
a/youtube-dl
b/youtube-dl
index cc6462cc004b1756ac945e13753a6080f0271318..153d4132fae31b7dc0f6e242eae30c65e6b99d14 100755
(executable)
--- a/
youtube-dl
+++ b/
youtube-dl
@@
-711,7
+711,9
@@
class FileDownloader(object):
return
try:
- os.makedirs(os.path.dirname(filename))
+ dn = os.path.dirname(filename)
+ if dn != '' and not os.path.exists(dn):
+ os.makedirs(dn)
except (OSError, IOError), err:
self.trouble(u'ERROR: unable to create directories: %s' % str(err))
return