mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-16 15:36:12 -04:00
Nearby Presence/Implementation: Fix for Android compile
PiperOrigin-RevId: 468735587
This commit is contained in:
committed by
Copybara-Service
parent
d92f1d4757
commit
5b7bb37d41
@@ -111,7 +111,7 @@ AdvertisementDecoder::DecodeAdvertisement(absl::string_view advertisement) {
|
||||
return elem.status();
|
||||
}
|
||||
if (elem->GetType() == DataElement::kSaltFieldType) {
|
||||
salt = elem->GetValue();
|
||||
salt = std::string(elem->GetValue());
|
||||
}
|
||||
bool need_decryption =
|
||||
IsIdentity(elem->GetType()) && !elem->GetValue().empty();
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
|
||||
#include "presence/implementation/base_broadcast_request.h"
|
||||
|
||||
#include <string>
|
||||
|
||||
#include "absl/strings/string_view.h"
|
||||
#include "internal/platform/logging.h"
|
||||
#include "presence/implementation/encryption.h"
|
||||
@@ -27,7 +29,7 @@ BasePresenceRequestBuilder& BasePresenceRequestBuilder::SetSalt(
|
||||
if (salt.size() != kSaltSize) {
|
||||
NEARBY_LOG(WARNING, "Unsupported salt length: %d", salt.size());
|
||||
} else {
|
||||
salt_ = salt;
|
||||
salt_ = std::string(salt);
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user