mirror of
https://github.com/Sude-/lgogdownloader.git
synced 2024-11-20 11:49:17 +01:00
Fix integer overflow when creating xml data
TiXmlElement::SetAttribute casted "size_t" to "int" which caused it to overflow
This commit is contained in:
parent
8115e591ca
commit
d31613dee7
@ -134,7 +134,7 @@ int Util::createXML(std::string filepath, size_t chunk_size, std::string xml_dir
|
||||
fileElem->SetAttribute("name", filename);
|
||||
fileElem->SetAttribute("md5", file_md5);
|
||||
fileElem->SetAttribute("chunks", chunks);
|
||||
fileElem->SetAttribute("total_size", filesize);
|
||||
fileElem->SetAttribute("total_size", std::to_string(filesize));
|
||||
|
||||
std::cout << "Getting MD5 for chunks" << std::endl;
|
||||
for (i = 0; i < chunks; i++) {
|
||||
|
Loading…
Reference in New Issue
Block a user