summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordbeam@chromium.org <dbeam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-19 18:47:48 +0000
committerdbeam@chromium.org <dbeam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-19 18:47:48 +0000
commite7d6293bf36c2e3c23c5789530ccfb4b99332daa (patch)
tree52f2d8bb629faf44a14364d881800bb67d8409bc
parent737087635548b4632b2959198ecabd8969a6d054 (diff)
downloadchromium_src-e7d6293bf36c2e3c23c5789530ccfb4b99332daa.zip
chromium_src-e7d6293bf36c2e3c23c5789530ccfb4b99332daa.tar.gz
chromium_src-e7d6293bf36c2e3c23c5789530ccfb4b99332daa.tar.bz2
Add base:: to string16 in rlz/.
R=rogerta@chromium.org BUG=329295 Review URL: https://codereview.chromium.org/102833007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241896 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--rlz/chromeos/lib/machine_id_chromeos.cc2
-rw-r--r--rlz/ios/lib/machine_id_ios.cc2
-rw-r--r--rlz/lib/machine_id.cc6
-rw-r--r--rlz/lib/machine_id.h4
-rw-r--r--rlz/lib/machine_id_unittest.cc2
-rw-r--r--rlz/mac/lib/machine_id_mac.cc2
-rw-r--r--rlz/test/rlz_test_helpers.cc8
-rw-r--r--rlz/win/lib/machine_id_win.cc2
8 files changed, 14 insertions, 14 deletions
diff --git a/rlz/chromeos/lib/machine_id_chromeos.cc b/rlz/chromeos/lib/machine_id_chromeos.cc
index 608fd03..e27de09 100644
--- a/rlz/chromeos/lib/machine_id_chromeos.cc
+++ b/rlz/chromeos/lib/machine_id_chromeos.cc
@@ -6,7 +6,7 @@
namespace rlz_lib {
-bool GetRawMachineId(string16* data, int* more_data) {
+bool GetRawMachineId(base::string16* data, int* more_data) {
// Machine IDs are not tracked for ChromeOS.
return false;
}
diff --git a/rlz/ios/lib/machine_id_ios.cc b/rlz/ios/lib/machine_id_ios.cc
index 3440978..b712dd9 100644
--- a/rlz/ios/lib/machine_id_ios.cc
+++ b/rlz/ios/lib/machine_id_ios.cc
@@ -8,7 +8,7 @@
namespace rlz_lib {
-bool GetRawMachineId(string16* data, int* more_data) {
+bool GetRawMachineId(base::string16* data, int* more_data) {
*data = ASCIIToUTF16(ios::device_util::GetDeviceIdentifier(NULL));
*more_data = 1;
return true;
diff --git a/rlz/lib/machine_id.cc b/rlz/lib/machine_id.cc
index b8c10f0..1919d02 100644
--- a/rlz/lib/machine_id.cc
+++ b/rlz/lib/machine_id.cc
@@ -22,7 +22,7 @@ bool GetMachineId(std::string* machine_id) {
return true;
}
- string16 sid_string;
+ base::string16 sid_string;
int volume_id;
if (!GetRawMachineId(&sid_string, &volume_id))
return false;
@@ -37,7 +37,7 @@ bool GetMachineId(std::string* machine_id) {
namespace testing {
-bool GetMachineIdImpl(const string16& sid_string,
+bool GetMachineIdImpl(const base::string16& sid_string,
int volume_id,
std::string* machine_id) {
machine_id->clear();
@@ -52,7 +52,7 @@ bool GetMachineIdImpl(const string16& sid_string,
// However, the chromebase SHA1 hash function takes only an std::string as
// input, so the unicode string needs to be converted to std::string
// "as is".
- size_t byte_count = sid_string.size() * sizeof(string16::value_type);
+ size_t byte_count = sid_string.size() * sizeof(base::string16::value_type);
const char* buffer = reinterpret_cast<const char*>(sid_string.c_str());
std::string sid_string_buffer(buffer, byte_count);
diff --git a/rlz/lib/machine_id.h b/rlz/lib/machine_id.h
index af58c8e..312f669 100644
--- a/rlz/lib/machine_id.h
+++ b/rlz/lib/machine_id.h
@@ -21,10 +21,10 @@ bool GetMachineId(std::string* machine_id);
// Retrieves a raw machine identifier string and a machine-specific
// 4 byte value. GetMachineId() will SHA1 |data|, append |more_data|, compute
// the Crc8 of that, and return a hex-encoded string of that data.
-bool GetRawMachineId(string16* data, int* more_data);
+bool GetRawMachineId(base::string16* data, int* more_data);
namespace testing {
-bool GetMachineIdImpl(const string16& sid_string,
+bool GetMachineIdImpl(const base::string16& sid_string,
int volume_id,
std::string* machine_id);
} // namespace testing
diff --git a/rlz/lib/machine_id_unittest.cc b/rlz/lib/machine_id_unittest.cc
index c01e9be..bcae511 100644
--- a/rlz/lib/machine_id_unittest.cc
+++ b/rlz/lib/machine_id_unittest.cc
@@ -11,7 +11,7 @@
// This test will fail if the behavior of GetMachineId changes.
TEST(MachineDealCodeTestMachineId, MachineId) {
- string16 computer_sid(UTF8ToUTF16(
+ base::string16 computer_sid(UTF8ToUTF16(
"S-1-5-21-2345599882-2448789067-1921365677"));
std::string id;
rlz_lib::testing::GetMachineIdImpl(computer_sid, 2651229008, &id);
diff --git a/rlz/mac/lib/machine_id_mac.cc b/rlz/mac/lib/machine_id_mac.cc
index f16175b..af39bb8 100644
--- a/rlz/mac/lib/machine_id_mac.cc
+++ b/rlz/mac/lib/machine_id_mac.cc
@@ -118,7 +118,7 @@ CFStringRef CopySerialNumber() {
} // namespace
-bool GetRawMachineId(string16* data, int* more_data) {
+bool GetRawMachineId(base::string16* data, int* more_data) {
uint8_t mac_address[kIOEthernetAddressSize];
data->clear();
diff --git a/rlz/test/rlz_test_helpers.cc b/rlz/test/rlz_test_helpers.cc
index af08836..d8b999f 100644
--- a/rlz/test/rlz_test_helpers.cc
+++ b/rlz/test/rlz_test_helpers.cc
@@ -33,14 +33,14 @@ const wchar_t kHKLMAccessProviders[] =
L"System\\CurrentControlSet\\Control\\Lsa\\AccessProviders";
struct RegistryValue {
- string16 name;
+ base::string16 name;
DWORD type;
std::vector<uint8> data;
};
struct RegistryKeyData {
std::vector<RegistryValue> values;
- std::map<string16, RegistryKeyData> keys;
+ std::map<base::string16, RegistryKeyData> keys;
};
void ReadRegistryTree(const base::win::RegKey& src, RegistryKeyData* data) {
@@ -63,7 +63,7 @@ void ReadRegistryTree(const base::win::RegKey& src, RegistryKeyData* data) {
for (base::win::RegistryKeyIterator i(src.Handle(), L"");
i.Valid(); ++i) {
ReadRegistryTree(base::win::RegKey(src.Handle(), i.Name(), KEY_READ),
- &data->keys[string16(i.Name())]);
+ &data->keys[base::string16(i.Name())]);
}
}
@@ -78,7 +78,7 @@ void WriteRegistryTree(const RegistryKeyData& data, base::win::RegKey* dest) {
}
// Next write values recursively.
- for (std::map<string16, RegistryKeyData>::const_iterator iter =
+ for (std::map<base::string16, RegistryKeyData>::const_iterator iter =
data.keys.begin();
iter != data.keys.end(); ++iter) {
WriteRegistryTree(iter->second,
diff --git a/rlz/win/lib/machine_id_win.cc b/rlz/win/lib/machine_id_win.cc
index 245b753..3f366fa 100644
--- a/rlz/win/lib/machine_id_win.cc
+++ b/rlz/win/lib/machine_id_win.cc
@@ -103,7 +103,7 @@ std::wstring ConvertSidToString(SID* sid) {
} // namespace
-bool GetRawMachineId(string16* sid_string, int* volume_id) {
+bool GetRawMachineId(base::string16* sid_string, int* volume_id) {
// Calculate the Windows SID.
wchar_t computer_name[MAX_COMPUTERNAME_LENGTH + 1] = {0};