Make sure that file is regular file when getting local hash

This commit is contained in:
Sude 2014-12-31 06:14:55 +02:00
parent 61e0c31775
commit 7d5874d312

View File

@ -2645,7 +2645,7 @@ std::string Downloader::getLocalFileHash(const std::string& filepath, const std:
}
else
{
if (boost::filesystem::exists(path))
if (boost::filesystem::exists(path) && boost::filesystem::is_regular_file(path))
{
localHash = Util::getFileHash(path.string(), RHASH_MD5);
}