Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(350)

Unified Diff: chrome/browser/chromeos/cros/cryptohome_library.cc

Issue 6869042: Add immutable settings checks when handling policy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add unit tests Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/cros/cryptohome_library.cc
diff --git a/chrome/browser/chromeos/cros/cryptohome_library.cc b/chrome/browser/chromeos/cros/cryptohome_library.cc
index 6c20330c8969d81983aebddac811ca88fdd23321..55dfa155cfa9cf9ebed85f7d1cfd389602877c57 100644
--- a/chrome/browser/chromeos/cros/cryptohome_library.cc
+++ b/chrome/browser/chromeos/cros/cryptohome_library.cc
@@ -245,7 +245,8 @@ class CryptohomeLibraryImpl : public CryptohomeLibrary {
class CryptohomeLibraryStubImpl : public CryptohomeLibrary {
public:
- CryptohomeLibraryStubImpl() {}
+ CryptohomeLibraryStubImpl()
+ : locked_(false) {}
virtual ~CryptohomeLibraryStubImpl() {}
bool CheckKey(const std::string& user_email, const std::string& passhash) {
@@ -399,7 +400,7 @@ class CryptohomeLibraryStubImpl : public CryptohomeLibrary {
}
bool InstallAttributesIsSecure() {
- return locked_;
+ return false;
}
bool InstallAttributesIsInvalid() {
@@ -407,7 +408,7 @@ class CryptohomeLibraryStubImpl : public CryptohomeLibrary {
}
bool InstallAttributesIsFirstInstall() {
- return false;
+ return !locked_;
}
private:

Powered by Google App Engine
This is Rietveld 408576698