Only hash file if remote XML is available

This commit is contained in:
Ismo Toijala 2014-05-08 18:05:02 +02:00 committed by Sude
parent caacff9f22
commit 6a5fe0b78e

View File

@ -881,10 +881,10 @@ CURLcode Downloader::downloadFile(const std::string& url, const std::string& fil
bool bSameVersion = true; // assume same version
bool bLocalXMLExists = boost::filesystem::exists(local_xml_file); // This is additional check to see if remote xml should be saved to speed up future version checks
std::string localHash = this->getLocalFileHash(filepath, gamename);
if (!xml_data.empty())
{
std::string localHash = this->getLocalFileHash(filepath, gamename);
// Do version check if local hash exists
if (!localHash.empty())
{