update_engine: Changes to delta minor version detection

Delta minor version should default to 1, the in-place algorithm minor
version, when the minor version is not given on the command line or in
the update_engine.conf file.

BUG=chromium:455493
TEST=`FEATURES=test emerge-link update_engine`

Change-Id: I510a19c4a3b88bae656c19ad1a6d24598586b6a9
Reviewed-on: https://chromium-review.googlesource.com/250560
Reviewed-by: Alex Deymo <deymo@chromium.org>
Tested-by: Allie Wood <alliewood@chromium.org>
Commit-Queue: Allie Wood <alliewood@chromium.org>
diff --git a/utils.cc b/utils.cc
index c512414..1f57672 100644
--- a/utils.cc
+++ b/utils.cc
@@ -1580,7 +1580,10 @@
   std::string result;
   if (base::PathExists(path) && store.Load(path) &&
       store.GetString("PAYLOAD_MINOR_VERSION", &result)) {
-    *minor_version = atoi(result.c_str());
+    if (!base::StringToUint(result, minor_version)) {
+      LOG(ERROR) << "StringToUint failed when parsing delta minor version.";
+      return false;
+    }
     return true;
   }
   return false;