diff options
author | msvensson@neptunus.(none) <> | 2006-09-25 16:40:29 +0200 |
---|---|---|
committer | msvensson@neptunus.(none) <> | 2006-09-25 16:40:29 +0200 |
commit | 64a64d0fbf29443cd0229bba0d7b2dfdf9624306 (patch) | |
tree | 1f8d7ab8dca1697f70a230f4fdcbd108cdf21ccf /extra/yassl/taocrypt/src/asn.cpp | |
parent | d8e27606e1716d674ce03588cb8e763fbc260b62 (diff) | |
download | mariadb-git-64a64d0fbf29443cd0229bba0d7b2dfdf9624306.tar.gz |
Import yaSSL version 1.4.0
Diffstat (limited to 'extra/yassl/taocrypt/src/asn.cpp')
-rw-r--r-- | extra/yassl/taocrypt/src/asn.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/extra/yassl/taocrypt/src/asn.cpp b/extra/yassl/taocrypt/src/asn.cpp index 45fb1e60a0c..3dc3638d85f 100644 --- a/extra/yassl/taocrypt/src/asn.cpp +++ b/extra/yassl/taocrypt/src/asn.cpp @@ -38,7 +38,8 @@ #include "sha.hpp" #include "coding.hpp" #include <time.h> // gmtime(); -#include "memory.hpp" // mySTL::auto_ptr +#include "memory.hpp" // some auto_ptr don't have reset, also need auto_array + namespace TaoCrypt { @@ -202,13 +203,13 @@ void PublicKey::SetKey(const byte* k) void PublicKey::AddToEnd(const byte* data, word32 len) { - mySTL::auto_ptr<byte> tmp(NEW_TC byte[sz_ + len], tcArrayDelete); + mySTL::auto_array<byte> tmp(NEW_TC byte[sz_ + len]); memcpy(tmp.get(), key_, sz_); memcpy(tmp.get() + sz_, data, len); byte* del = 0; - mySTL::swap(del, key_); + STL::swap(del, key_); tcArrayDelete(del); key_ = tmp.release(); @@ -856,7 +857,7 @@ bool CertDecoder::ValidateSignature(SignerList* signers) bool CertDecoder::ConfirmSignature(Source& pub) { HashType ht; - mySTL::auto_ptr<HASH> hasher(tcDelete); + mySTL::auto_ptr<HASH> hasher; if (signatureOID_ == MD5wRSA) { hasher.reset(NEW_TC MD5); |