Snap for 12508860 from 163424eacc9da44f65d493c0190dd05eaa840f3f to 25Q1-release

Change-Id: I56f29ed08987878dcd5caba69132e5474437fa9e
diff --git a/payload_generator/payload_generation_config.cc b/payload_generator/payload_generation_config.cc
index 839960e..20c5e04 100644
--- a/payload_generator/payload_generation_config.cc
+++ b/payload_generator/payload_generation_config.cc
@@ -22,7 +22,6 @@
 
 #include <android-base/parseint.h>
 #include <base/logging.h>
-#include <base/strings/string_number_conversions.h>
 #include <brillo/strings/string_utils.h>
 #include <libsnapshot/cow_format.h>
 
@@ -176,7 +175,7 @@
     }
 
     uint64_t max_size{};
-    if (!base::StringToUint64(buf, &max_size)) {
+    if (!android::base::ParseUint<uint64_t>(buf, &max_size)) {
       LOG(ERROR) << "Group size for " << group_name << " = " << buf
                  << " is not an integer.";
       return false;
diff --git a/payload_generator/payload_signer.cc b/payload_generator/payload_signer.cc
index 4b24eba..b661a92 100644
--- a/payload_generator/payload_signer.cc
+++ b/payload_generator/payload_signer.cc
@@ -23,7 +23,6 @@
 
 #include <base/logging.h>
 #include <base/strings/string_number_conversions.h>
-#include <base/strings/string_util.h>
 #include <brillo/data_encoding.h>
 #include <openssl/err.h>
 #include <openssl/pem.h>
diff --git a/payload_generator/xz_chromeos.cc b/payload_generator/xz_chromeos.cc
deleted file mode 100644
index 2ff9458..0000000
--- a/payload_generator/xz_chromeos.cc
+++ /dev/null
@@ -1,54 +0,0 @@
-//
-// Copyright (C) 2016 The Android Open Source Project
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-#include "update_engine/payload_generator/xz.h"
-
-#include <base/logging.h>
-#include <lzma.h>
-
-namespace chromeos_update_engine {
-
-void XzCompressInit() {}
-
-bool XzCompress(const brillo::Blob& in, brillo::Blob* out) {
-  out->clear();
-  if (in.empty())
-    return true;
-
-  // Resize the output buffer to get enough memory for writing the compressed
-  // data.
-  out->resize(lzma_stream_buffer_bound(in.size()));
-
-  const uint32_t kLzmaPreset = 6;
-  size_t out_pos = 0;
-  int rc = lzma_easy_buffer_encode(kLzmaPreset,
-                                   LZMA_CHECK_NONE,  // We do not need CRC.
-                                   nullptr,
-                                   in.data(),
-                                   in.size(),
-                                   out->data(),
-                                   &out_pos,
-                                   out->size());
-  if (rc != LZMA_OK) {
-    LOG(ERROR) << "Failed to compress data to LZMA stream with return code: "
-               << rc;
-    return false;
-  }
-  out->resize(out_pos);
-  return true;
-}
-
-}  // namespace chromeos_update_engine