summaryrefslogtreecommitdiffstats
path: root/chrome/browser/webdata
diff options
context:
space:
mode:
authordbeam@chromium.org <dbeam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-22 00:44:53 +0000
committerdbeam@chromium.org <dbeam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-22 00:44:53 +0000
commit30ace79421e9cda0463cf2b7dc5a2ea62827528a (patch)
tree4e6dfe2b6286562ee497d32613cbd5174981ade8 /chrome/browser/webdata
parentb375d7f4f0ac281e1012d031a4f90f27fec1b9eb (diff)
downloadchromium_src-30ace79421e9cda0463cf2b7dc5a2ea62827528a.zip
chromium_src-30ace79421e9cda0463cf2b7dc5a2ea62827528a.tar.gz
chromium_src-30ace79421e9cda0463cf2b7dc5a2ea62827528a.tar.bz2
[Coverity] Change some pass by values to pass by const refs.
CID=8501 CID=100223 R=dhollowa@chromium.org Review URL: http://codereview.chromium.org/9006038 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@115456 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/webdata')
-rw-r--r--chrome/browser/webdata/autofill_change.cc4
-rw-r--r--chrome/browser/webdata/autofill_change.h4
2 files changed, 4 insertions, 4 deletions
diff --git a/chrome/browser/webdata/autofill_change.cc b/chrome/browser/webdata/autofill_change.cc
index 454d7b9..e6bb085 100644
--- a/chrome/browser/webdata/autofill_change.cc
+++ b/chrome/browser/webdata/autofill_change.cc
@@ -15,7 +15,7 @@ AutofillChange::~AutofillChange() {
}
AutofillProfileChange::AutofillProfileChange(
- Type type, std::string key, const AutofillProfile* profile)
+ Type type, const std::string& key, const AutofillProfile* profile)
: GenericAutofillChange<std::string>(type, key),
profile_(profile) {
DCHECK(type == ADD ? (profile && profile->guid() == key) : true);
@@ -34,7 +34,7 @@ bool AutofillProfileChange::operator==(
}
AutofillCreditCardChange::AutofillCreditCardChange(
- Type type, std::string key, const CreditCard* credit_card)
+ Type type, const std::string& key, const CreditCard* credit_card)
: GenericAutofillChange<std::string>(type, key), credit_card_(credit_card) {
DCHECK(type == ADD ? (credit_card && credit_card->guid() == key) : true);
DCHECK(type == UPDATE ? (credit_card && credit_card->guid() == key) : true);
diff --git a/chrome/browser/webdata/autofill_change.h b/chrome/browser/webdata/autofill_change.h
index 297a6a7..079a94a 100644
--- a/chrome/browser/webdata/autofill_change.h
+++ b/chrome/browser/webdata/autofill_change.h
@@ -54,7 +54,7 @@ class AutofillProfileChange : public GenericAutofillChange<std::string> {
// When |type| == UPDATE, |profile| should be non-NULL.
// When |type| == REMOVE, |profile| should be NULL.
AutofillProfileChange(Type type,
- std::string key,
+ const std::string& key,
const AutofillProfile* profile);
virtual ~AutofillProfileChange();
@@ -75,7 +75,7 @@ class AutofillCreditCardChange : public GenericAutofillChange<std::string> {
// When |type| == UPDATE, |credit_card| should be non-NULL.
// When |type| == REMOVE, |credit_card| should be NULL.
AutofillCreditCardChange(Type type,
- std::string key,
+ const std::string& key,
const CreditCard* credit_card);
virtual ~AutofillCreditCardChange();