Fix incorrect creation of directory while downloading.

This commit is contained in:
Andrey Smirnov
2013-12-17 21:22:50 +04:00
parent 151a4acfa7
commit e0e4b74c58
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -92,7 +92,7 @@ func (downloader *downloaderImpl) handleTask(task *downloadTask) {
return
}
err = os.MkdirAll(filepath.Base(task.destination), 0755)
err = os.MkdirAll(filepath.Dir(task.destination), 0755)
if err != nil {
task.result <- err
return