| Index: base/crypto/signature_creator_nss.cc
|
| diff --git a/base/crypto/signature_creator_nss.cc b/base/crypto/signature_creator_nss.cc
|
| index ff1d2717775352590f70b056fb23df8ef8c91d1b..4cc2c10cda326117d6dc54a845a284be0eb56fb0 100644
|
| --- a/base/crypto/signature_creator_nss.cc
|
| +++ b/base/crypto/signature_creator_nss.cc
|
| @@ -14,6 +14,13 @@
|
|
|
| namespace base {
|
|
|
| +SignatureCreator::~SignatureCreator() {
|
| + if (sign_context_) {
|
| + SGN_DestroyContext(sign_context_, PR_TRUE);
|
| + sign_context_ = NULL;
|
| + }
|
| +}
|
| +
|
| // static
|
| SignatureCreator* SignatureCreator::Create(RSAPrivateKey* key) {
|
| scoped_ptr<SignatureCreator> result(new SignatureCreator);
|
| @@ -35,17 +42,6 @@ SignatureCreator* SignatureCreator::Create(RSAPrivateKey* key) {
|
| return result.release();
|
| }
|
|
|
| -SignatureCreator::SignatureCreator() : sign_context_(NULL) {
|
| - EnsureNSSInit();
|
| -}
|
| -
|
| -SignatureCreator::~SignatureCreator() {
|
| - if (sign_context_) {
|
| - SGN_DestroyContext(sign_context_, PR_TRUE);
|
| - sign_context_ = NULL;
|
| - }
|
| -}
|
| -
|
| bool SignatureCreator::Update(const uint8* data_part, int data_part_len) {
|
| // TODO(wtc): Remove this const_cast when we require NSS 3.12.5.
|
| // See NSS bug https://bugzilla.mozilla.org/show_bug.cgi?id=518255
|
| @@ -73,4 +69,8 @@ bool SignatureCreator::Final(std::vector<uint8>* signature) {
|
| return true;
|
| }
|
|
|
| +SignatureCreator::SignatureCreator() : sign_context_(NULL) {
|
| + EnsureNSSInit();
|
| +}
|
| +
|
| } // namespace base
|
|
|