partially revert "Cleanup remaining errors; .." in certkeys.c
Roumen Petrov <[email protected]> Sat, 10 Jun 2017 21:05:43 +0300
| Newsgroups | gmane.text.xml.xmlsec |
|---|---|
| Message-ID | <[email protected]> |
Hi Aleksey,
In certkeys.c one of conversion to error functions is not correct - GCC
mingw complier warns with:
.....
make[3]: Entering directory `..../src/mscrypto'
CC libxmlsec1_mscrypto_la-certkeys.lo
In file included from globals.h:29:0,
from certkeys.c:10:
certkeys.c: In function 'xmlSecMSCryptoCertAdopt':
../errors_helpers.h:516:21: warning: cast from pointer to integer of
different size [-Wpointer-to-int-cast]
(unsigned long)(actual), \
^
certkeys.c:902:9: note: in expansion of macro
'xmlSecInvalidIntegerTypeError'
xmlSecInvalidIntegerTypeError("PCCERT_CONTEXT key type",
^
.....
Work-around is temporary to restore previous code - see attachment
0007-partially-revert-Cleanup-remaining-errors-.-in-certk.patch
Roumen
_______________________________________________
xmlsec mailing list
[email protected]
http://www.aleksey.com/mailman/listinfo/xmlsec
0007-partially-revert-Cleanup-remaining-errors-.-in-certk.patch
(text/x-diff, 1.1 KB)
From f38b13b364996556f87169b4cc0e7ce6f9ba48c4 Mon Sep 17 00:00:00 2001 From: Roumen Petrov <[email protected]> Date: Sat, 10 Jun 2017 13:58:05 -0400 Subject: [PATCH 7/7] partially revert "Cleanup remaining errors;.." in certkeys.c --- src/mscrypto/certkeys.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/mscrypto/certkeys.c b/src/mscrypto/certkeys.c index 439f6c2..690ff95 100644 --- a/src/mscrypto/certkeys.c +++ b/src/mscrypto/certkeys.c @@ -899,9 +899,11 @@ xmlSecMSCryptoCertAdopt(PCCERT_CONTEXT pCert, xmlSecKeyDataType type) { #endif /* XMLSEC_NO_GOST*/ if (NULL == data) { - xmlSecInvalidIntegerTypeError("PCCERT_CONTEXT key type", - pCert->pCertInfo->SubjectPublicKeyInfo.Algorithm.pszObjId, - "supported keytype", NULL); + xmlSecError(XMLSEC_ERRORS_HERE, + NULL, + NULL, + XMLSEC_ERRORS_R_INVALID_TYPE, + "PCCERT_CONTEXT key type %s not supported", pCert->pCertInfo->SubjectPublicKeyInfo.Algorithm.pszObjId); return(NULL); } -- 1.8.3.1