Index: chrome/browser/sync/test/integration/performance/autofill_sync_perf_test.cc |
diff --git a/chrome/browser/sync/test/integration/performance/autofill_sync_perf_test.cc b/chrome/browser/sync/test/integration/performance/autofill_sync_perf_test.cc |
index 5a74e7d876c15507cd875dc14a7dcf25ba2c5024..ae64606dcc7d58e6bd1c5cdfc4823cfdc5cd6e1f 100644 |
--- a/chrome/browser/sync/test/integration/performance/autofill_sync_perf_test.cc |
+++ b/chrome/browser/sync/test/integration/performance/autofill_sync_perf_test.cc |
@@ -55,28 +55,28 @@ class AutofillSyncPerfTest : public SyncTest { |
private: |
// Returns a new unique autofill profile. |
- const AutofillProfile NextAutofillProfile(); |
+ const AutofillProfile& NextAutofillProfile(); |
// Returns a new unique autofill key. |
- const AutofillKey NextAutofillKey(); |
+ const AutofillKey& NextAutofillKey(); |
// Returns an unused unique guid. |
- const std::string NextGUID(); |
+ const std::string& NextGUID(); |
// Returns a unique guid based on the input integer |n|. |
- const std::string IntToGUID(int n); |
+ const std::string& IntToGUID(int n); |
// Returns a new unused unique name. |
- const std::string NextName(); |
+ const std::string& NextName(); |
// Returns a unique name based on the input integer |n|. |
- const std::string IntToName(int n); |
+ const std::string& IntToName(int n); |
// Returns a new unused unique value for autofill entries. |
- const std::string NextValue(); |
+ const std::string& NextValue(); |
// Returnes a unique value based on the input integer |n|. |
- const std::string IntToValue(int n); |
+ const std::string& IntToValue(int n); |
int guid_number_; |
int name_number_; |
@@ -122,7 +122,7 @@ void AutofillSyncPerfTest::AddKeys(int profile, int num_keys) { |
autofill_helper::AddKeys(profile, keys); |
} |
-const AutofillProfile AutofillSyncPerfTest::NextAutofillProfile() { |
+const AutofillProfile& AutofillSyncPerfTest::NextAutofillProfile() { |
AutofillProfile profile; |
autofill::test::SetProfileInfoWithGuid(&profile, NextGUID().c_str(), |
NextName().c_str(), "", "", "", "", "", |
@@ -130,31 +130,31 @@ const AutofillProfile AutofillSyncPerfTest::NextAutofillProfile() { |
return profile; |
} |
-const AutofillKey AutofillSyncPerfTest::NextAutofillKey() { |
+const AutofillKey& AutofillSyncPerfTest::NextAutofillKey() { |
return AutofillKey(NextName().c_str(), NextName().c_str()); |
} |
-const std::string AutofillSyncPerfTest::NextGUID() { |
+const std::string& AutofillSyncPerfTest::NextGUID() { |
return IntToGUID(guid_number_++); |
} |
-const std::string AutofillSyncPerfTest::IntToGUID(int n) { |
+const std::string& AutofillSyncPerfTest::IntToGUID(int n) { |
return base::StringPrintf("00000000-0000-0000-0000-%012X", n); |
} |
-const std::string AutofillSyncPerfTest::NextName() { |
+const std::string& AutofillSyncPerfTest::NextName() { |
return IntToName(name_number_++); |
} |
-const std::string AutofillSyncPerfTest::IntToName(int n) { |
+const std::string& AutofillSyncPerfTest::IntToName(int n) { |
return base::StringPrintf("Name%d", n); |
} |
-const std::string AutofillSyncPerfTest::NextValue() { |
+const std::string& AutofillSyncPerfTest::NextValue() { |
return IntToValue(value_number_++); |
} |
-const std::string AutofillSyncPerfTest::IntToValue(int n) { |
+const std::string& AutofillSyncPerfTest::IntToValue(int n) { |
return base::StringPrintf("Value%d", n); |
} |