Index: crypto/scoped_test_system_nss_key_slot.cc |
diff --git a/crypto/scoped_test_system_nss_key_slot.cc b/crypto/scoped_test_system_nss_key_slot.cc |
index ee5e1dfaa274d0c756bc13a20450d6670cc57f03..169443d3359deec834c7b3007a5ce9acb8b45f97 100644 |
--- a/crypto/scoped_test_system_nss_key_slot.cc |
+++ b/crypto/scoped_test_system_nss_key_slot.cc |
@@ -9,20 +9,26 @@ |
namespace crypto { |
-ScopedTestSystemNSSKeySlot::ScopedTestSystemNSSKeySlot() |
+ScopedTestSystemNSSKeySlot::ScopedTestSystemNSSKeySlot( |
+ bool skip_tpm_initialization) |
: test_db_(new ScopedTestNSSDB) { |
if (!test_db_->is_open()) |
return; |
SetSystemKeySlotForTesting( |
+ skip_tpm_initialization, |
ScopedPK11Slot(PK11_ReferenceSlot(test_db_->slot()))); |
} |
ScopedTestSystemNSSKeySlot::~ScopedTestSystemNSSKeySlot() { |
- SetSystemKeySlotForTesting(ScopedPK11Slot()); |
+ SetSystemKeySlotForTesting(false, ScopedPK11Slot()); |
} |
bool ScopedTestSystemNSSKeySlot::ConstructedSuccessfully() const { |
return test_db_->is_open(); |
} |
+PK11SlotInfo* ScopedTestSystemNSSKeySlot::slot() const { |
+ return test_db_->slot(); |
+} |
+ |
} // namespace crypto |