ItemUpdater: Store version id as string instead of int
The version id is a string hash, and sometimes when converted to
int, it's a bigger number than int can hold. Store the id as a
string instead as the version numbers are not necessarily in order
since it's a hash, not an increasing number sequence.
Change-Id: Iaaa92627d5a2b4548a653e8d974d1aa8ce80be3c
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
diff --git a/item_updater.cpp b/item_updater.cpp
index 77dfe1c..95e71de 100755
--- a/item_updater.cpp
+++ b/item_updater.cpp
@@ -55,7 +55,7 @@
return -1;
}
- auto versionId = std::stoi(resp.substr(pos + 1), nullptr, 16);
+ auto versionId = resp.substr(pos + 1);
if (updater->activations.find(versionId) == updater->activations.end())
{
updater->activations.insert(std::make_pair(