diff options
author | qsr@chromium.org <qsr@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2011-10-10 14:02:29 +0000 |
---|---|---|
committer | qsr@chromium.org <qsr@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2011-10-10 14:02:29 +0000 |
commit | da1c36d03ec9553a5da53b21b18e1b946d45dcff (patch) | |
tree | 4ff3c80d3e6fae76bb1418af85e703cf9a974048 /src/common/mac | |
parent | Do not commit user preferences for xcodeproj. (diff) | |
download | breakpad-da1c36d03ec9553a5da53b21b18e1b946d45dcff.tar.xz |
Extracting the config file class from the Inspector to be able to reuse it.
This will be needed for iOS implementation, where the Inspector won't be
used, but where a config file will still be needed, because the uploads
won't happen just after the crash, but on a next run.
Review URL: http://breakpad.appspot.com/309001
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@852 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/common/mac')
-rw-r--r-- | src/common/mac/SimpleStringDictionary.h | 2 | ||||
-rw-r--r-- | src/common/mac/SimpleStringDictionary.mm | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/common/mac/SimpleStringDictionary.h b/src/common/mac/SimpleStringDictionary.h index 3d6c27bd..814a6f7a 100644 --- a/src/common/mac/SimpleStringDictionary.h +++ b/src/common/mac/SimpleStringDictionary.h @@ -134,7 +134,7 @@ class SimpleStringDictionary { // Given |key|, returns its corresponding |value|. // If |key| is NULL, an assert will fire or NULL will be returned. If |key| // is not found or is an empty string, NULL is returned. - const char *GetValueForKey(const char *key); + const char *GetValueForKey(const char *key) const; // Stores a string |value| represented by |key|. If |key| is NULL or an empty // string, this will assert (or do nothing). If |value| is NULL then diff --git a/src/common/mac/SimpleStringDictionary.mm b/src/common/mac/SimpleStringDictionary.mm index d9c791cc..b97b760c 100644 --- a/src/common/mac/SimpleStringDictionary.mm +++ b/src/common/mac/SimpleStringDictionary.mm @@ -55,13 +55,13 @@ int SimpleStringDictionary::GetCount() const { } //============================================================================== -const char *SimpleStringDictionary::GetValueForKey(const char *key) { +const char *SimpleStringDictionary::GetValueForKey(const char *key) const { assert(key); if (!key) return NULL; for (int i = 0; i < MAX_NUM_ENTRIES; ++i) { - KeyValueEntry &entry = entries_[i]; + const KeyValueEntry &entry = entries_[i]; if (entry.IsActive() && !strcmp(entry.GetKey(), key)) { return entry.GetValue(); } |