summaryrefslogtreecommitdiff
path: root/asn.cpp
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2019-09-29 23:54:04 -0400
committerJeffrey Walton <noloader@gmail.com>2019-09-29 23:54:04 -0400
commite4b25dcffed47ce799caef4d290590816ca19708 (patch)
treec2ea87998d7277084d4a4e86e71a48197f7246a9 /asn.cpp
parent2656798bf166d3d2dba9b35d928d0d6e562c8137 (diff)
downloadcryptopp-git-e4b25dcffed47ce799caef4d290590816ca19708.tar.gz
Fix compile error due to missing BytePtr overload
This is a local change on a testing fork. It is not tested for Master yet.
Diffstat (limited to 'asn.cpp')
-rw-r--r--asn.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/asn.cpp b/asn.cpp
index 729c7760..231125c4 100644
--- a/asn.cpp
+++ b/asn.cpp
@@ -158,7 +158,7 @@ size_t DEREncodeTextString(BufferedTransformation &bt, const byte* str, size_t s
size_t DEREncodeTextString(BufferedTransformation &bt, const SecByteBlock &str, byte asnTag)
{
- return DEREncodeTextString(bt, ConstBytePtr(str), BytePtrSize(str), asnTag);
+ return DEREncodeTextString(bt, str, str.size(), asnTag);
}
size_t DEREncodeTextString(BufferedTransformation &bt, const std::string &str, byte asnTag)
@@ -179,7 +179,7 @@ size_t BERDecodeTextString(BufferedTransformation &bt, SecByteBlock &str, byte a
BERDecodeError();
str.resize(bc);
- if (bc != bt.Get(BytePtr(str), BytePtrSize(str)))
+ if (bc != bt.Get(str, str.size()))
BERDecodeError();
return bc;
@@ -208,7 +208,7 @@ size_t DEREncodeDate(BufferedTransformation &bt, const SecByteBlock &str, byte a
{
bt.Put(asnTag);
size_t lengthBytes = DERLengthEncode(bt, str.size());
- bt.Put(ConstBytePtr(str), BytePtrSize(str));
+ bt.Put(str, str.size());
return 1+lengthBytes+str.size();
}
@@ -225,7 +225,7 @@ size_t BERDecodeDate(BufferedTransformation &bt, SecByteBlock &str, byte asnTag)
BERDecodeError();
str.resize(bc);
- if (bc != bt.Get(BytePtr(str), BytePtrSize(str)))
+ if (bc != bt.Get(str, str.size()))
BERDecodeError();
return bc;