From a577a258132981f41596595f1109676503df99a3 Mon Sep 17 00:00:00 2001 From: aj Date: Fri, 20 Jul 2007 13:47:17 +0000 Subject: [PATCH] silence a warning we get with siemens cards. git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3226 c6295689-39f2-0310-b995-f0e70906c6a9 --- src/libopensc/pkcs15-pubkey.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/libopensc/pkcs15-pubkey.c b/src/libopensc/pkcs15-pubkey.c index 274b7c68..3e32033e 100644 --- a/src/libopensc/pkcs15-pubkey.c +++ b/src/libopensc/pkcs15-pubkey.c @@ -215,8 +215,10 @@ int sc_pkcs15_encode_pukdf_entry(sc_context_t *ctx, return r; } +/* this should be required, not optional. But it is missing in some siemens cards and thus causes warnings */ +/* so we silence these warnings by making it optional - the card works ok without. :/ */ static struct sc_asn1_entry c_asn1_public_key[2] = { - { "publicKeyCoefficients", SC_ASN1_STRUCT, SC_ASN1_TAG_SEQUENCE | SC_ASN1_CONS, 0, NULL, NULL }, + { "publicKeyCoefficients", SC_ASN1_STRUCT, SC_ASN1_TAG_SEQUENCE | SC_ASN1_CONS, SC_ASN1_OPTIONAL, NULL, NULL }, { NULL, 0, 0, 0, NULL, NULL } };