summaryrefslogtreecommitdiffstats
path: root/crypto/asn1
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2015-10-18 00:54:13 +0100
committerDr. Stephen Henson <steve@openssl.org>2015-10-18 12:13:54 +0100
commit7f3e6f8c243710b8dc89f385196987ad83c7848d (patch)
tree5edaec86475c2cd00e479be058f77ce4da3f7a9e /crypto/asn1
parenteb05f17344c6538d9ee48770d963ae2c1822d070 (diff)
set string type when embedding
Reviewed-by: Tim Hudson <tjh@openssl.org>
Diffstat (limited to 'crypto/asn1')
-rw-r--r--crypto/asn1/tasn_new.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/crypto/asn1/tasn_new.c b/crypto/asn1/tasn_new.c
index 33a8e97442..6a2ad62d70 100644
--- a/crypto/asn1/tasn_new.c
+++ b/crypto/asn1/tasn_new.c
@@ -352,6 +352,7 @@ static int asn1_primitive_new(ASN1_VALUE **pval, const ASN1_ITEM *it,
if (embed) {
str = *(ASN1_STRING **)pval;
memset(str, 0, sizeof(*str));
+ str->type = utype;
str->flags = ASN1_STRING_FLAG_EMBED;
} else {
str = ASN1_STRING_type_new(utype);