mirror of https://github.com/aria2/aria2
Allow block device file to -i option
parent
bebd602ba7
commit
14e995d2bc
|
@ -529,8 +529,10 @@ std::shared_ptr<UriListParser> openUriListParser(const std::string& filename)
|
|||
listPath = DEV_STDIN;
|
||||
}
|
||||
else {
|
||||
if (!File(filename).isFile()) {
|
||||
throw DL_ABORT_EX(fmt(EX_FILE_OPEN, filename.c_str(), "No such file"));
|
||||
auto f = File(filename);
|
||||
if (!f.exists() || f.isDir()) {
|
||||
throw DL_ABORT_EX(fmt(EX_FILE_OPEN, filename.c_str(),
|
||||
"File not found or it is a directory"));
|
||||
}
|
||||
listPath = filename;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue