diff --git a/dlls/crypt32/cert.c b/dlls/crypt32/cert.c index 75d26a4119f..9cef6f8de19 100644 --- a/dlls/crypt32/cert.c +++ b/dlls/crypt32/cert.c @@ -88,7 +88,7 @@ PCCERT_CONTEXT WINAPI CertCreateCertificateContext(DWORD dwCertEncodingType, { BYTE *data = NULL; - cert = (PCERT_CONTEXT)Context_CreateDataContext(sizeof(CERT_CONTEXT)); + cert = Context_CreateDataContext(sizeof(CERT_CONTEXT)); if (!cert) goto end; data = CryptMemAlloc(cbCertEncoded); @@ -601,7 +601,7 @@ static BOOL CRYPT_AcquirePrivateKeyFromProvInfo(PCCERT_CONTEXT pCert, CERT_KEY_PROV_INFO_PROP_ID, 0, &size); if (ret) { - info = (PCRYPT_KEY_PROV_INFO)HeapAlloc(GetProcessHeap(), 0, size); + info = HeapAlloc(GetProcessHeap(), 0, size); if (info) { ret = CertGetCertificateContextProperty(pCert, @@ -661,8 +661,7 @@ BOOL WINAPI CryptAcquireCertificatePrivateKey(PCCERT_CONTEXT pCert, CERT_KEY_PROV_INFO_PROP_ID, 0, &size); if (ret) { - info = (PCRYPT_KEY_PROV_INFO)HeapAlloc( - GetProcessHeap(), 0, size); + info = HeapAlloc(GetProcessHeap(), 0, size); ret = CertGetCertificateContextProperty(pCert, CERT_KEY_PROV_INFO_PROP_ID, info, &size); if (ret) diff --git a/dlls/crypt32/context.c b/dlls/crypt32/context.c index 959d0c9d8dd..fa085817ac6 100644 --- a/dlls/crypt32/context.c +++ b/dlls/crypt32/context.c @@ -207,7 +207,7 @@ static inline struct list *ContextList_ContextToEntry(struct ContextList *list, struct list *ret; if (context) - ret = (struct list *)Context_GetExtra(context, list->contextSize); + ret = Context_GetExtra(context, list->contextSize); else ret = NULL; return ret; diff --git a/dlls/crypt32/crl.c b/dlls/crypt32/crl.c index 23c623fe1f3..9ae0d5d8aad 100644 --- a/dlls/crypt32/crl.c +++ b/dlls/crypt32/crl.c @@ -50,7 +50,7 @@ PCCRL_CONTEXT WINAPI CertCreateCRLContext(DWORD dwCertEncodingType, { BYTE *data = NULL; - crl = (PCRL_CONTEXT)Context_CreateDataContext(sizeof(CRL_CONTEXT)); + crl = Context_CreateDataContext(sizeof(CRL_CONTEXT)); if (!crl) goto end; data = CryptMemAlloc(cbCrlEncoded); diff --git a/dlls/crypt32/ctl.c b/dlls/crypt32/ctl.c index 9b6d2e0128c..ffac6674dfd 100644 --- a/dlls/crypt32/ctl.c +++ b/dlls/crypt32/ctl.c @@ -382,8 +382,7 @@ PCCTL_CONTEXT WINAPI CertCreateCTLContext(DWORD dwMsgAndCertEncodingType, (BYTE *)&ctlInfo, &size); if (ret) { - ctl = (PCTL_CONTEXT)Context_CreateDataContext( - sizeof(CTL_CONTEXT)); + ctl = Context_CreateDataContext(sizeof(CTL_CONTEXT)); if (ctl) { BYTE *data = CryptMemAlloc(cbCtlEncoded); diff --git a/dlls/crypt32/store.c b/dlls/crypt32/store.c index 834cc1d8ce4..1519c968ee0 100644 --- a/dlls/crypt32/store.c +++ b/dlls/crypt32/store.c @@ -156,7 +156,7 @@ static BOOL CRYPT_MemAddCert(PWINECRYPT_CERTSTORE store, void *cert, TRACE("(%p, %p, %p, %p)\n", store, cert, toReplace, ppStoreContext); - context = (PCERT_CONTEXT)ContextList_Add(ms->certs, cert, toReplace); + context = ContextList_Add(ms->certs, cert, toReplace); if (context) { context->hCertStore = store; @@ -197,7 +197,7 @@ static BOOL CRYPT_MemAddCrl(PWINECRYPT_CERTSTORE store, void *crl, TRACE("(%p, %p, %p, %p)\n", store, crl, toReplace, ppStoreContext); - context = (PCRL_CONTEXT)ContextList_Add(ms->crls, crl, toReplace); + context = ContextList_Add(ms->crls, crl, toReplace); if (context) { context->hCertStore = store; @@ -238,7 +238,7 @@ static BOOL CRYPT_MemAddCtl(PWINECRYPT_CERTSTORE store, void *ctl, TRACE("(%p, %p, %p, %p)\n", store, ctl, toReplace, ppStoreContext); - context = (PCTL_CONTEXT)ContextList_Add(ms->ctls, ctl, toReplace); + context = ContextList_Add(ms->ctls, ctl, toReplace); if (context) { context->hCertStore = store;