Snap for 12260156 from bd3bcc1c78d3a5d2d300ea4355e536569a954b81 to 24Q4-release
Change-Id: I53124e66d379305fabd552ec5cdd21247be1955f
diff --git a/aosp/update_attempter_android.cc b/aosp/update_attempter_android.cc
index 909ce59..857685f 100644
--- a/aosp/update_attempter_android.cc
+++ b/aosp/update_attempter_android.cc
@@ -391,11 +391,11 @@
auto entries =
android::base::Split(headers[kPayloadPropertyHTTPExtras], " ");
for (auto& entry : entries) {
- auto parts = android::base::Split(entry, ":");
+ auto parts = android::base::Split(entry, ";");
if (parts.size() != 2) {
LOG(ERROR)
<< "HTTP headers are not in expected format. "
- "headers[kPayloadPropertyHTTPExtras] = key1:val1 key2:val2";
+ "headers[kPayloadPropertyHTTPExtras] = key1;val1 key2;val2";
continue;
}
fetcher->SetHeader(parts[0], parts[1]);
diff --git a/common/constants.h b/common/constants.h
index 6b1bf6b..dcd181f 100644
--- a/common/constants.h
+++ b/common/constants.h
@@ -163,7 +163,7 @@
static constexpr const auto& kPayloadPropertyMetadataHash = "METADATA_HASH";
// The Authorization: HTTP header to be sent when downloading the payload.
static constexpr const auto& kPayloadPropertyAuthorization = "AUTHORIZATION";
-// HTTP headers extra entries in the format of key1:val1 key2:val2 key3:val3
+// HTTP headers extra entries in the format of key1;val1 key2;val2 key3;val3
static constexpr const auto& kPayloadPropertyHTTPExtras = "HTTP_EXTRAS";
// The User-Agent HTTP header to be sent when downloading the payload.
static constexpr const auto& kPayloadPropertyUserAgent = "USER_AGENT";
diff --git a/payload_consumer/filesystem_verifier_action.cc b/payload_consumer/filesystem_verifier_action.cc
index 93e61bf..2934fb7 100644
--- a/payload_consumer/filesystem_verifier_action.cc
+++ b/payload_consumer/filesystem_verifier_action.cc
@@ -319,7 +319,7 @@
return;
}
const auto read_size =
- std::min<size_t>(buffer_size, end_offset - start_offset);
+ std::min<uint64_t>(buffer_size, end_offset - start_offset);
const auto bytes_read = fd->Read(buffer, read_size);
if (bytes_read < 0 || static_cast<size_t>(bytes_read) != read_size) {
PLOG(ERROR) << "Failed to read offset " << start_offset << " expected "